creativecommons / chooser

The new and improved CC license selection tool.
https://chooser-beta.creativecommons.org
MIT License
105 stars 141 forks source link

Validation Errors in Attribution Details Input text field #342

Closed Cronus1007 closed 3 years ago

Cronus1007 commented 3 years ago

Problem Description

The Link To Work input feild, Link To Creator Work and Year of Creation input feild accepts any value hich are not in the proper fashion even. So in accordance to these input field setting up of proper Validation of these fields is necessary in my point of view and displaying an error message if something garbage has been sent in these input fields.

Solution Description

Validation of the input fields is required. Screenshot from 2021-03-08 23-19-17

Implementation

obulat commented 3 years ago

Form field validation is necessary before the data is sent to the server to prevent attacks such as SQL injection. Chooser does not send any information to the server, so it is not necessary. These values are only used to create the license code on the 'Mark Your Work' section. We have already discussed sanitizing user input in #177, so you can find more context there.

zackkrida commented 3 years ago

@Cronus1007 to elaborate, a single user is consuming their own input + output in one sitting, only on the client-side, so we don't need to validate the information at all. What they type is what they'll get.