flatpress icon indicating copy to clipboard operation
flatpress copied to clipboard

Missing check of the character set input

Open Fraenkiman opened this issue 11 months ago • 1 comments

Hello everyone,

There is no validation whether the character set input in the admin area is valid or invalid. Currently I could enter a Bochum car license plate as character set and FlatPress does not defend itself.

With best regards Frank

Fraenkiman avatar Mar 16 '24 00:03 Fraenkiman

Two compatible character sets are specified in the file fp-interface/lang/en-us/lang.conf.php. It may be possible to specify a third and fourth character set here and use it for validation.

https://github.com/flatpressblog/flatpress/blob/1a3ae63d632b909dd0044e7793b5b9b75ad157fe/fp-interface/lang/en-us/lang.conf.php#L5

It would be even more elegant to turn the free input field into a dropdown field that uses the character sets from lang.conf.php.

https://github.com/flatpressblog/flatpress/blob/1a3ae63d632b909dd0044e7793b5b9b75ad157fe/admin/panels/config/admin.config.tpl#L168

Fraenkiman avatar Mar 25 '24 15:03 Fraenkiman