adorsys/XS2A-Sandbox

Error on TPP-Redirect-URI header length

matthieu526 opened this issue · 5 comments

Hello,

It seems like the header TPP-Redirect-URI (and I guess TPP-Nok-Redirect-URI too) have a limit of 255 characters because of the error Header 'tpp-redirect-uri' should not be more than 255 symbols.
Where does this limit come from? It doesn't come from Berlin Group specification as they don't impose any limit there.
I know that in our case it will be an issue. Some state that we add to the redirect URIs makes the whole header more than 255 symbols.
Would it be possible to increase this limit?

Thanks a lot,
Matthieu

@matthieu526 Hello, Berlin Group specification v.1.3.6 says:

Max35Text, Max70Text, Max140Text and Max500Text are defining strings with a maximum length of 35, 70, 140 and 500 characters respectively.

So the length will be increased to Max500Text.

These are indeed types that exist. But they are not used for any headers, only as part of request bodies.
You can see in the paragraph above the once you cited

The character set is UTF 8 encoded. This specification is only using the basic data elements "String", "Boolean", "ISODateTime", "ISODate", "UUID" and "Integer" (with a byte length of 32 bits) and ISO based code lists. For codes defined by ISO, a reference to the corresponding ISO standard is given in 14.34.

For headers, the type String is used, and shouldn't have any limit in size.

@matthieu526 What is the length of the URI you are going to use?

It is not set as the values are encoded, but at the moment they are around 240 characters.
A Max500Text will work for us for quite some time that's for sure.

@matthieu526 Done. You can check it in v.3.7.1