Dear rossisimone,
We are a group of Academic researchers. We are analyzing vulnerable C++ code snippets migrated from StackOverflow to GitHub. Our research will be published in Academic publications and will not be used in any Industrial application.
We noted a vulnerable code snippet in your repository that was most likely copied from Stack Overflow. The vulnerability exists in this source code file of your repository.
Please verify our report here with regards to the above vulnerability to assist you.
Link to report with four questions for you related to the vulnerability (should not take more than 5 minutes to answer).
Here is a summary of the vulnerable code snippet:
Description:
This function fails when folder has . in its name and file has no extension.
example:/folder1/folder2/folder.name.with.dots/bin (file without extension) will return:
/folder1/folder2/folder.name.with
In some cases this is very important since it'll be used in input validation and may result in compromising the system.
Mitigation:
Either use this function only on file name or use Boost library:
Please verify our report here with regards to the above vulnerability to assist you.
Link to report with four questions for you related to the vulnerability (should not take more than 5 minutes to answer).
Dear rossisimone, We are a group of Academic researchers. We are analyzing vulnerable C++ code snippets migrated from StackOverflow to GitHub. Our research will be published in Academic publications and will not be used in any Industrial application. We noted a vulnerable code snippet in your repository that was most likely copied from Stack Overflow. The vulnerability exists in this source code file of your repository.
Please verify our report here with regards to the above vulnerability to assist you. Link to report with four questions for you related to the vulnerability (should not take more than 5 minutes to answer).
Here is a summary of the vulnerable code snippet:
Description:
This function fails when folder has
.
in its name and file has no extension. example:/folder1/folder2/folder.name.with.dots/bin
(file without extension) will return:/folder1/folder2/folder.name.with
In some cases this is very important since it'll be used in input validation and may result in compromising the system.Mitigation:
Either use this function only on file name or use Boost library:
References:
https://stackoverflow.com/a/30800163/3686236
Please verify our report here with regards to the above vulnerability to assist you. Link to report with four questions for you related to the vulnerability (should not take more than 5 minutes to answer).
Sincerely yours, Morteza Verdi, Shiraz university, E-mail: m.verdi@shirazu.ac.ir Jafar Akhondali, Shiraz university, E-mail: jafar.akhondali@yahoo.com Ashkan Sami, Shiraz university, E-mail: ashkan.sami@gmail.com Foutse Khomh, Polytechnique Montreal, E-mail: foutse.khomh@polymtl.ca, website: http://www.khomh.net/ Gias Uddin, Polytechnique Montreal, E-mail: gias98@gmail.com, website: https://giasuddin.github.io Alireza Karami motlagh, Shahid Chamran University, E-mail: alireza.karami.m@gmail.com