json-schema-spec
json-schema-spec copied to clipboard
add security note about accessing urls
What kind of change does this PR introduce?
clarification
Issue & Discussion References
- Closes #1231
Summary
Adds a security note about performing network operations when encountering URLs.
The last sentence in the addition was taken directly from @awwright's comment in the issue.
Does this PR introduce a breaking change?
no
Minor issue, but otherwise looks good. Thanks!
FWIW this is what I note for security considerations in my implementation -- https://metacpan.org/pod/JSON::Schema::Modern#SECURITY-CONSIDERATIONS -- as regular expressions provide a potential vector for executing code or creating a DoS.
@karenetheridge thank you. I notice that what you have is particularly focused on regular expressions, which are already included in the validation spec.
I notice that what you have is particularly focused on regular expressions
Yes, since I don't support fetching schemas from disk or the network, I think this is the only direct source of vulnerabilities that a user might not already be aware of.
I think the key to emphasize (and we can repeat it in a few places if relevant) is "do not trust schemas from external sources".
Go for it. I'm spinning wheels with this one.