Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

security update: add check on improperly encoded input #29

Merged
merged 6 commits into from Jun 2, 2022
Merged

Conversation

wolkykim
Copy link
Owner

@wolkykim wolkykim commented Jun 1, 2022

  • improve sanity check on url encoded string input which fixes possible security issue reported recently
  • added unit tests for the cases

Details in regard to who found it and reported will be released if they are ok with it in the future release announcement.
Great thanks to whom kindly reported this issue to us.

---[Test Output]---

$ make test
gcc -Wall -fPIC -g -I./ -D_GNU_SOURCE -I/usr/include -I/usr/local/include -I../src -c -o test_q_urldecode.o test_q_urldecode.c
gcc -Wall -fPIC -g -I./ -D_GNU_SOURCE -I/usr/include -I/usr/local/include -I../src -c -o qunit.o qunit.c
gcc -Wall -fPIC -g -I./ -D_GNU_SOURCE -I/usr/include -I/usr/local/include -I../src -o test_q_urldecode test_q_urldecode.o qunit.o ../src/libqdecoder.a
Test internal.c/_q_urldecode
======================================================================
* TEST : Test plain strings . OK (1 assertions, 0ms)
* TEST : Test urlencoded strings ... OK (3 assertions, 0ms)
* TEST : Test exceptions ....... OK (7 assertions, 0ms)
======================================================================
PASS - 3/3 tests passed.

======================================================================
****             Good job! All tests are successful               ****
======================================================================
*   ____                 _     All tests have finished successfully. *
*  / ___| ___   ___   __| |     | | ___ | |__   | |                  *
* | |  _ / _ \ / _ \ / _` |  _  | |/ _ \| '_ \  | |                  *
* | |_| | (_) | (_) | (_| | | |_| | (_) | |_) | |_|                  *
*  \____|\___/ \___/ \__,_|  \___/ \___/|_.__/  (_)                  *
======================================================================

@wolkykim wolkykim merged commit 40d8718 into master Jun 2, 2022
@wolkykim wolkykim deleted the secfix branch June 2, 2022 03:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant