Skip to content

Flashmap matching logic fails when target params are encoded. [SPR-9657] #14291

Closed
@spring-projects-issues

Description

@spring-projects-issues

David Victor opened SPR-9657 and commented

In our app we handle some request parameters which contain unicode characters.
Our web.xml has the familiar org.springframework.web.filter.CharacterEncodingFilter enabled to encode using UTF-8.

One of our handler methods in a controller class redirects on success - and we add a success alert message to the flashmap in RedirectAttributes. We also add a couple of attributes to the "redirect model". This ends up with an encoded parameter in 'targetParams' - which fails to match to the relevant request via isFlashMapForRequest() in AbstractFlashMapManager.

Will try to add more useful detail - but am on limit of my knowledge here, and been banging head against this for a day now. The impact is that within our app the 'XXX successfully complete' flash message in the UI does not appear - due to not matching the flashmap - for encoded parameters. Fortunately these are in the minority - but its quite odd when the message mostly appears - and then sometimes doesn't. :-)


Affects: 3.1 GA

Sub-tasks:

Issue Links:

Metadata

Metadata

Assignees

Labels

in: webIssues in web modules (web, webmvc, webflux, websocket)type: bugA general bug

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions