-
Notifications
You must be signed in to change notification settings - Fork 473
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
dispenser: add input validation #4713
Conversation
37b1218
to
c4eadb9
Compare
Codecov Report
@@ Coverage Diff @@
## master #4713 +/- ##
==========================================
- Coverage 54.49% 54.44% -0.06%
==========================================
Files 407 407
Lines 52425 52425
==========================================
- Hits 28569 28542 -27
- Misses 21472 21492 +20
- Partials 2384 2391 +7
📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
c4eadb9
to
24eb850
Compare
cmd/dispenser/index.html.tpl
Outdated
const queryString = window.location.search; | ||
const urlParams = new URLSearchParams(queryString); | ||
const account = sanitize(urlParams.get('account')) | ||
const pattern = /[A-Z0-9]{58}/ |
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.
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.
Good on you for pulling this HTML template out of the server side code.
@excalq I mainly did it because it didn't like embeded backticks, but it's also cleaner. |
25d3702
to
7fba75f
Compare
7fba75f
to
456f0d9
Compare
Summary
text()
instead ofhtml()
References