CPSA ยท Web application assessment: recon, access control and input
Information in web mark-up
Hidden form fields, connection strings, credentials, developer comments, included files and authenticated-only URLs.
Key points
- The HTML and JavaScript delivered to the browser can leak data even when it is not displayed: developer comments (credentials, queries, internal IPs), hidden form fields (prices, roles, IDs), included script files (API keys, internal or admin routes), source map files and meta tags.
- Read the raw source and every included file, and remember that hidden means unseen, not protected.
Practice questions
How does a tester normally see the contents of a hidden form field?
- By viewing the page source or inspecting the DOM
- By cracking the field's encryption
- By guessing the server's database password
- By waiting for the user to type it
Show answer
Answer: A. By viewing the page source or inspecting the DOM
Hidden fields are part of the HTML sent to the client, so viewing the page source or using developer tools shows them. They are not encrypted and no special exploit is needed.
Which findings in page source are worth reporting?
- A comment containing a database username and password
- The CSS colour palette
- A script that references an internal admin route
- The current CPU load of the server
- A hidden field carrying the user's role
Show answer
Answer: A. A comment containing a database username and password, C. A script that references an internal admin route, E. A hidden field carrying the user's role
Credentials in comments, internal endpoints in scripts and trusted role values in hidden fields all expose sensitive data or logic. A CSS colour palette and the server's CPU load are not in the markup and are harmless.
True or false: a value in a hidden form field is safe from tampering because the user cannot see it.
Show answer
Answer: False
False. Hidden only affects rendering. The user can read and change the value with developer tools or an intercepting proxy.
Practice 8 questions on this topic in Bitzu
Short lessons, instant explanations and spaced review of what you get wrong. Free on iOS and Android.
