Skip to content

Commit f96a229

Browse files
committed
Add warning about the use of IdPMetadataParser class
1 parent e2ca369 commit f96a229

File tree

2 files changed

+9
-0
lines changed

2 files changed

+9
-0
lines changed

README.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,13 @@ In production, the **onelogin.saml2.strict** setting parameter MUST be set as **
7272

7373
In production also we highly recommend to register on the settings the IdP certificate instead of using the fingerprint method. The fingerprint, is a hash, so at the end is open to a collision attack that can end on a signature validation bypass. Other SAML toolkits deprecated that mechanism, we maintain it for compatibility and also to be used on test environment.
7474

75+
The IdPMetadataParser class does not validate in any way the URL that is introduced in order to be parsed.
76+
77+
Usually the same administrator that handles the Service Provider also sets the URL to the IdP, which should be a trusted resource.
78+
79+
But there are other scenarios, like a SAAS app where the administrator of the app delegates this functionality to other users. In this case, extra precaution should be taken in order to validate such URL inputs and avoid attacks like SSRF.
80+
81+
7582
## Installation
7683
### Hosting
7784
#### Github

core/src/main/java/com/onelogin/saml2/settings/IdPMetadataParser.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,8 @@
2424
*
2525
* A class that implements the settings parser from IdP Metadata
2626
*
27+
* This class does not validate in any way the URL that is introduced,
28+
* make sure to validate it properly before use it in a get_metadata method.
2729
*/
2830
public class IdPMetadataParser {
2931

0 commit comments

Comments
 (0)