Html tags in in the message and the messagePerField fields [keycloakify 10]
Hello! First of all, I would like to thank you for this library. I enjoy working with Keycloakify.
I migrated to Keycloak 25, which required me to upgrade to the release candidate 10.0.0-rc.100.
In the new version, I have noticed that message.summary and messagesPerFields contain HTML tags.
I don't know it is a expected behavior or it is a bug.
Currently, I am sanitizing the HTML, but I am not sure if this is the correct approach.
import DOMPurify from 'dompurify';
export const getCleanString = (input: string) => {
return DOMPurify.sanitize(input, { ALLOWED_TAGS: [], ALLOWED_ATTR: [] });
};
This is an example.
https://github.com/keycloakify/keycloakify/pull/538
Hello @GusevDV,
Glad you're having a good experiece!
Good catch, it's my bad, I'll address this
Sorry for the delay, here are the changes: https://github.com/keycloakify/keycloakify/commit/7c257d97a741c36f1ace4f48caccfee8944c4d0b
Thank you very much for a quick solution!