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

Fix code scanning alert no. 1: Double escaping or unescaping #98

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

brw
Copy link
Member

@brw brw commented Oct 29, 2024

Fixes https://github.com/Team-BTMC/osu-radio/security/code-scanning/1

To fix the double escaping issue, we need to ensure that backslashes are escaped before any other characters. This way, any existing backslashes are correctly handled before other replacements are made. We will modify the changeSongHighlight function to first escape backslashes and then escape double quotes.

Suggested fixes powered by Copilot Autofix. Review carefully before merging.

Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>
@brw
Copy link
Member Author

brw commented Oct 29, 2024

Hm yes, very interesting

@brw brw marked this pull request as ready for review October 29, 2024 01:45
@brw brw requested a review from CaptSiro as a code owner October 29, 2024 01:45
@brw brw removed the request for review from CaptSiro October 29, 2024 01:58
@brw brw requested a review from Copilot November 19, 2024 19:42
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.

1 participant