-
Notifications
You must be signed in to change notification settings - Fork 126
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.
Many thanks for your contribution, and in particular for diligently hunting down so many XPath packages! This broadly looks good to me; I've made a few suggestions. (@sauyon, feel free to chip in with any other comments you might have.)
^ Pro tip: in the "Files changed" view, you have the option of adding review suggestions to a batch and commit them all at once. |
Co-Authored-By: Max Schaefer <54907921+max-schaefer@users.noreply.github.com>
Thanks for the tip. Even after 5 years of GitHub there is still new stuff to learn :) Changes: |
Use getUnderlyingType() to account for named aliases. Co-Authored-By: Max Schaefer <54907921+max-schaefer@users.noreply.github.com>
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.
LGTM, thank you very much for your contribution!
An XPath injection query is available for C#, JavaScript, Java but not for Go.
This pull request consist of an XPath Injection query to detect cases in which user input is used unsafely included in an XPath query.
I'm pretty much new to the Go language, so I hope my example code works.
I'm also new to the Go QL flavour so I've added a TODO which I'm currently not sure how to solve.
Query help is inspired/ported from the C# query help.
Code will be autoformatted soon.