CVE-2017-12873
Incorrect persistent NameID generation in SimpleSAMLphp
SimpleSAMLphp 1.7.0 through 1.14.10 might allow attackers to obtain sensitive information, gain unauthorized access, or have unspecified other impacts by leveraging incorrect persistent NameID generation when an Identity Provider (IdP) is misconfigured.
Attack profile
How easy it is to exploit
- Attack vector
- Network
- Complexity
- Low
- Privileges needed
- None
- User interaction
- None
What an attacker can affect
- Confidentiality
- High
- Integrity
- High
- Availability
- High
Exploit likelihood
What each source reports
NVD Score used
9.8
SimpleSAMLphp 1.7.0 through 1.14.10 might allow attackers to obtain sensitive information, gain unauthorized access, or have unspecified other impacts by leveraging incorrect persistent NameID generation when an Identity Provider (IdP) is misconfigured.
- Record
CVE-2017-12873- CVSS 3.0
- 9.8 Critical
CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H - CVSS 2.0
- 7.5 High
AV:N/AC:L/Au:N/C:P/I:P/A:P - Weakness
- CWE-384
- Updated
- 2026-11-02
CVE List No score
SimpleSAMLphp 1.7.0 through 1.14.10 might allow attackers to obtain sensitive information, gain unauthorized access, or have unspecified other impacts by leveraging incorrect persistent NameID generation when an Identity Provider (IdP) is misconfigured.
- Record
CVE-2017-12873- Updated
- 2026-11-02
EUVDEUVD-2020-0265 No score
SimpleSAMLphp 1.7.0 through 1.14.10 might allow attackers to obtain sensitive information, gain unauthorized access, or have unspecified other impacts by leveraging incorrect persistent NameID generation when an Identity Provider (IdP) is misconfigured.
- Record
EUVD-2020-0265- Updated
- 2026-11-03
GitHub AdvisoriesGHSA-gp2m-7cfp-h6gf
9.8
Incorrect persistent NameID generation in SimpleSAMLphp
Background
When a SimpleSAMLphp Identity Provider is misconfigured, a bug in the software when trying to build a persistent NameID to univocally identify the authenticating subject could cause different users to get the same identifier generated, depending on the attributes available for them right after authentication.
Please note that even though this is possible thanks to a bug, an IdP must be misconfigured to release persistent NameIDs even if it is not properly configured to generate them based on the specifics of the deployment.
Description
Persistent NameIDs will typically be sent as part of the Subject element of a SAML assertion, or as the contents of the eduPersonTargetedID attribute. Here is an example of such a NameID:
<NameID Format=“urn:oasis:names:tc:SAML:2.0:nameid-format:persistent“>
zbonsm0Yn9Gnw14uQEEPr6AO7d+IvxwCQN3t+o24jYs=
</NameID>
Some service providers will use this information to identify a user across sessions because a persistent NameID will never change for a given user. This could lead to different users accessing the same account in those service providers.
In order to be affected by this issue, the following circumstances must concur:
- SimpleSAMLphp acts as an identity provider.
- The service provider asking for authentication requests a persistent
NameID. - No
saml:PersistentNameIDauthentication processing filter is configured (neither for the whole IdP, nor for a given SP). - No
simplesaml.nameidattributeconfiguration option is set (neither for the whole IdP, nor for a given SP). - One of the following alternatives:
- No
userid.attributeconfiguration option is set and the users don't have aneduPersonPrincipalNameattribute in the users backend, or - the
userid.attributeconfiguration option is set to an empty or missing attribute.
- No
If all these requirements are met, the SimpleSAML_Auth_ProcessingChain class will try to keep a unique user identifier in the state array (addUserID() method). Bear in mind that this code is executed before all the authentication processing filters configured, meaning that only those attributes retrieved for the user during initial authentication will be available. If no userid.attribute configuration option is set, the default eduPersonPrincipalName will then be used. However, since it is missing, no identifier will be kept. Alternatively, if userid.attribute is set to a missing or empty attribute, the addUserID() method will abort trying to register an identifier.
After executing all authentication processing filters, SimpleSAMLphp will build a SAML assertion. If the service provider requests persistent NameIDs, SimpleSAMLphp will attempt to generate one given that none is already available (because the saml:PersistentNameID filter was not used). At this point, the code will look for the simplesaml.nameidattribute configuration option in either the local IdP metadata or in the remote SP metadata. If none of them are configured, it will default to the unique user identifier previously registered by SimpleSAML_Auth_ProcessingChain. If no identifier was kept there, the code will log an error message:
Unable to generate NameID. Check the userid.attribute option.
However, instead of aborting the NameID generation at that point, it will go on and use a value missing from the state array as the source for the computation, meaning the null type will be used. Hence, all users connecting to a given service provider will get the same NameID generated, because all the input parameters will be the same:
- The SP's entity identifier.
- The IdP's entity identifier.
- The
nullvalue. - The common secret salt from the main configuration.
Affected versions
All SimpleSAMLphp versions between 1.7.0 and 1.14.10, inclusive.
Impact
Those identity providers affected by this bug and misconfigured as previously described could be issuing SAML assertions…
- Record
GHSA-gp2m-7cfp-h6gf- CVSS 3.0
- 9.8 Critical
CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H - Weakness
- CWE-384
- Updated
- 2026-11-02
OSV
9.8
SimpleSAMLphp 1.7.0 through 1.14.10 might allow attackers to obtain sensitive information, gain unauthorized access, or have unspecified other impacts by leveraging incorrect persistent NameID generation when an Identity Provider (IdP) is misconfigured.
- Record
CVE-2017-12873- CVSS 3.0
- 9.8 Critical
CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H - Updated
- 2026-11-02
OSVDEBIAN-CVE-2017-12873
9.8
SimpleSAMLphp 1.7.0 through 1.14.10 might allow attackers to obtain sensitive information, gain unauthorized access, or have unspecified other impacts by leveraging incorrect persistent NameID generation when an Identity Provider (IdP) is misconfigured.
- Record
DEBIAN-CVE-2017-12873- CVSS 3.0
- 9.8 Critical
CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H - Updated
- 2026-11-02
OSVGHSA-gp2m-7cfp-h6gf
9.8
Incorrect persistent NameID generation in SimpleSAMLphp
Background
When a SimpleSAMLphp Identity Provider is misconfigured, a bug in the software when trying to build a persistent NameID to univocally identify the authenticating subject could cause different users to get the same identifier generated, depending on the attributes available for them right after authentication.
Please note that even though this is possible thanks to a bug, an IdP must be misconfigured to release persistent NameIDs even if it is not properly configured to generate them based on the specifics of the deployment.
Description
Persistent NameIDs will typically be sent as part of the Subject element of a SAML assertion, or as the contents of the eduPersonTargetedID attribute. Here is an example of such a NameID:
<NameID Format=“urn:oasis:names:tc:SAML:2.0:nameid-format:persistent“>
zbonsm0Yn9Gnw14uQEEPr6AO7d+IvxwCQN3t+o24jYs=
</NameID>
Some service providers will use this information to identify a user across sessions because a persistent NameID will never change for a given user. This could lead to different users accessing the same account in those service providers.
In order to be affected by this issue, the following circumstances must concur:
- SimpleSAMLphp acts as an identity provider.
- The service provider asking for authentication requests a persistent
NameID. - No
saml:PersistentNameIDauthentication processing filter is configured (neither for the whole IdP, nor for a given SP). - No
simplesaml.nameidattributeconfiguration option is set (neither for the whole IdP, nor for a given SP). - One of the following alternatives:
- No
userid.attributeconfiguration option is set and the users don't have aneduPersonPrincipalNameattribute in the users backend, or - the
userid.attributeconfiguration option is set to an empty or missing attribute.
- No
If all these requirements are met, the SimpleSAML_Auth_ProcessingChain class will try to keep a unique user identifier in the state array (addUserID() method). Bear in mind that this code is executed before all the authentication processing filters configured, meaning that only those attributes retrieved for the user during initial authentication will be available. If no userid.attribute configuration option is set, the default eduPersonPrincipalName will then be used. However, since it is missing, no identifier will be kept. Alternatively, if userid.attribute is set to a missing or empty attribute, the addUserID() method will abort trying to register an identifier.
After executing all authentication processing filters, SimpleSAMLphp will build a SAML assertion. If the service provider requests persistent NameIDs, SimpleSAMLphp will attempt to generate one given that none is already available (because the saml:PersistentNameID filter was not used). At this point, the code will look for the simplesaml.nameidattribute configuration option in either the local IdP metadata or in the remote SP metadata. If none of them are configured, it will default to the unique user identifier previously registered by SimpleSAML_Auth_ProcessingChain. If no identifier was kept there, the code will log an error message:
Unable to generate NameID. Check the userid.attribute option.
However, instead of aborting the NameID generation at that point, it will go on and use a value missing from the state array as the source for the computation, meaning the null type will be used. Hence, all users connecting to a given service provider will get the same NameID generated, because all the input parameters will be the same:
- The SP's entity identifier.
- The IdP's entity identifier.
- The
nullvalue. - The common secret salt from the main configuration.
Affected versions
All SimpleSAMLphp versions between 1.7.0 and 1.14.10, inclusive.
Impact
Those identity providers affected by this bug and misconfigured as previously described could be issuing SAML assertions…
- Record
GHSA-gp2m-7cfp-h6gf- CVSS 3.0
- 9.8 Critical
CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H - Weakness
- CWE-384
- Updated
- 2026-11-02
OSVUBUNTU-CVE-2017-12873
9.8
SimpleSAMLphp 1.7.0 through 1.14.10 might allow attackers to obtain sensitive information, gain unauthorized access, or have unspecified other impacts by leveraging incorrect persistent NameID generation when an Identity Provider (IdP) is misconfigured.
- Record
UBUNTU-CVE-2017-12873- CVSS 3.0
- 9.8 Critical
CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H - Updated
- 2026-11-02
Affected products
Affected packages
| Package | Affected | Fixed |
|---|---|---|
simplesamlphp/simplesamlphpPackagist |
1.7.0 up to 1.14.11 | 1.14.11 |
simplesamlphpDebian:12 |
before 1.14.11-1 | 1.14.11-1 |
simplesamlphpDebian:14 |
before 1.14.11-1, plus listed versions 1.10.0-11.11.0-11.12.0-11.12.0~rc1-11.12.0~rc2-1 Show 32 moreShow less1.13.0-11.13.1-11.13.1-21.13.2-11.14.0-11.14.1-11.14.10-11.14.2-11.14.2-21.14.3-11.14.4-11.14.5-11.14.6-11.14.7-11.14.8-11.14.9-11.6.0-11.6.1-11.6.2-11.6.3-11.6.3-21.6.3-31.7.0-11.7.0-21.8.0-11.8.1-11.8.2-11.9.0-11.9.0~rc1-11.9.0~rc2-11.9.1-11.9.2-1 |
1.14.11-1 |
simplesamlphpDebian:7 |
before 1.9.2-1+deb7u1, plus listed versions 1.9.2-1 |
1.9.2-1+deb7u1 |
simplesamlphpDebian:8 |
before 1.13.1-2+deb8u1, plus listed versions 1.13.1-2 |
1.13.1-2+deb8u1 |
simplesamlphpDebian:9 |
before 1.14.11-1+deb9u1, plus listed versions 1.14.11-1 |
1.14.11-1+deb9u1 |
simplesamlphp/simplesamlphpPackagist |
1.7.0 up to 1.14.11, plus listed versions v1.12.0v1.13.0v1.13.0-rc1v1.13.0-rc2v1.13.1 Show 13 moreShow lessv1.13.2v1.14.0v1.14.0-rc1v1.14.1v1.14.10v1.14.2v1.14.3v1.14.4v1.14.5v1.14.6v1.14.7v1.14.8v1.14.9 |
1.14.11 |
simplesamlphpUbuntu:Pro:16.04:LTS |
All versions, plus listed versions 1.13.2-11.14.0-11.14.0-1ubuntu21.14.0-1ubuntu2+esm1 |
None known |
History
| Recorded | Changed | Sources |
|---|---|---|
| aliases | EUVD | |
| first indexed | CVE List, GitHub Advisories, NVD, OSV |
Dates are when Every CVE recorded each change. Upstream dates may differ.
In short
CVE-2017-12873 is a critical vulnerability (CVSS 9.8) in Simplesamlphp, published September 1, 2017. No source lists public exploit code. EPSS puts the chance of exploitation in the next 30 days at 1.66%, the 76th percentile. Fixed in simplesamlphp/simplesamlphp 1.14.11.
References
github.com/simplesamlphp/simplesamlphp/commit/90dca835158495b173808273e7df127303b8b953
lists.debian.org/debian-lts-announce/2017/12/msg00007.html
simplesamlphp.org/security/201612-04
debian.org/security/2018/dsa-4127
github.com/simplesamlphp/simplesamlphp/security/advisories/GHSA-gp2m-7cfp-h6gf
nvd.nist.gov/vuln/detail/CVE-2017-12873
Left out here: the rest of 2 source descriptions. The JSON record has them.