-
-
Notifications
You must be signed in to change notification settings - Fork 139
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
add https connection and allowed hosts check #1575
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The security issue highlighted concerns untrusted URL redirection from a remote source, where user input is incorporated into a URL redirect without full validation, leading to potential phishing attacks (CWE-601). The proposed change ensures that the scheme is HTTPS and the netloc is in the allowed hosts. However, this may not fully mitigate the risk as it does not address the validation of the entire URL, such as the path and query parameters which can also be exploited.
To address the issue more comprehensively, consider implementing the following:
- Validate the full URL structure, not just the scheme and netloc.
- Ensure that the path and query parameters do not redirect to an untrusted page even if the netloc is within the allowed hosts.
- Use a list of allowed paths or a regular expression to validate the entire redirection endpoint.
- Employ a safe redirect function that only redirects to known-safe URLs defined within the application.
Implementing these additional checks will help to ensure that the application is not vulnerable to open redirection attacks stemming from user input.
@MattSilverio the github , google and facebook callback function have to be updated. What you have to do is : read those social media documents and implement it on the BLT, which I'm going gonna do after few days, or if you can do that, implement this one, but don't do something like sanitization system cause this is mainly feature problem, not a security one. best of luck ☺ |
This pull request sets up GitHub code scanning for this repository. Once the scans have completed and the checks have passed, the analysis results for this pull request branch will appear on this overview. Once you merge this pull request, the 'Security' tab will show more code scanning analysis results (for example, for the default branch). Depending on your configuration and choice of analysis tool, future pull requests will be annotated with code scanning analysis results. For more information about GitHub code scanning, check out the documentation. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Additional checks implemented as requested, @DonnieBLT
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
looks good, just let me know about the file
Resolving problem to issue #1553