Phishing vulnerability: Template generation allows external parameters to override placeholders

Bug #1919419 reported by Etienne Dysli Metref
258
This bug affects 1 person
Affects Status Importance Assigned to Milestone
shibboleth-sp (Debian)
Fix Released
Unknown
shibboleth-sp (Ubuntu)
Fix Released
Medium
Steve Beattie

Bug Description

Upstream advisory: https://shibboleth.net/community/advisories/secadv_20210317.txt

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512

Shibboleth Service Provider Security Advisory [17 March 2021]

An updated version of the Service Provider software is available
which fixes a phishing vulnerability.

Template generation allows external parameters to override placeholders
======================================================================
The SP includes a primitive template engine used to render error pages
and various other status or transition pages, and it supports a syntax
for embedding placeholders that are replaced by internally supplied
values or configuration settings.

For reasons that are unclear in the code history, it was extended to
allow replacement via query parameters also, though this is not a
typical need. Because of this feature, it's possible to cause the SP
to display some templates containing values supplied externally by
URL manipulation.

Though the values are encoded to prevent script injection, the content
nevertheless appears to come from the server and so would be interpreted
as trustworthy, allowing email addresses, logos and style sheets, or
support URLs to be manipulated by an attacker.

All platforms are impacted by this issue.

Recommendations
===============
Update to V3.2.1 or later of the Service Provider software, which
is now available.

The update adds a new <Errors> setting to the configuration called
externalParameters, which defaults to false. When false, support for
this "feature" is disabled. In the unlikely event that a valid need
for this exists, the setting can be enabled temporarily to maintain
function until the use case requiring it is addressed in some other
way.

In the event that an update is not possible, reducing or eliminating
some of the more sensitive template replacement values with static
values in the templates may decrease the impact.

Other Notes
===========
The cpp-sp git commit containing the fix for this issue is
d1dbebfadc1bdb824fea63843c4c38fa69e54379

Credits
=======
Toni Huttunen, Fraktal Oy

History
=======
Edited to add credit, and a bit more discussion of style sheet risk
and workarounds.

URL for this Security Advisory:
https://shibboleth.net/community/advisories/secadv_20210317.txt

-----BEGIN PGP SIGNATURE-----

iQIzBAEBCgAdFiEE3KoVAHvtneaQzZUjN4uEVAIneWIFAmBSD+MACgkQN4uEVAIn
eWJQtBAAp3xxDvDxiQ3bNw+vwJmEOVjJMlwLjBQPmYvV09Pu593xuQj4RWLbZRgK
lZlxHzvXb6dg+bHNl799uCFhcWe8NExB5GnTQPR8/JG1OwgJ0WogezpMYAAvKjkA
LXaDsz7u4DDQ4OBYemkMx3W+0CHhYPw+TLz9rHN+rAKOEGzPLWDT/cKJ75ps19/v
hnQKZ7i7mQobh61zAe5rpi+ziWmDqhzFv4uBOwbuY02UYZQm6+D3BRqAf62Cjnyh
Z/nuZ6Z/5BxitDZBPPSreSl7sMHYzI83RDZGHWgEDjHKZdpYSXpUM3vntuC1pdaO
r4izd97H7nptnuznslu1S0NfkeZlWF3XaaMa8ZrCvMvC62MVK+WvOgFZxE5wmeDZ
3f9Eei//LTE4+B1rQPU99wNbgXdelfXWKkN6hHIXcSlfqG4miAONA86U39JuNovy
S66o9uQG3y55Qp9YcGAca4/9azmr8xQlcKTPFfp2tJrvCwmK3yu0TPbeirPpE9SN
eJhl3/cCenOyN9pMZOZ9MqeIPdlkJ1Qwcd1xs/Jyzqo/LTsvnzVTzaCx0lc6qy/Z
ld3Amkcpo/K2NajWjFVvwx72Yj4Y3DCUvlDrQcNM8Oc2Sv195EDJpXIW8ynqB9aZ
RJUrsmhKRcQKMbfGlHAToMREruW1i3jH1twqS/IOxe7Z4jg5u3A=
=tv1A
-----END PGP SIGNATURE-----

Upstream bug: https://issues.shibboleth.net/jira/browse/SSPCPP-922
Upstream patch: https://git.shibboleth.net/view/?p=cpp-sp.git;a=commit;h=d1dbebfadc1bdb824fea63843c4c38fa69e54379

CVE References

description: updated
information type: Private Security → Public Security
Changed in shibboleth-sp (Debian):
status: Unknown → Confirmed
Revision history for this message
Etienne Dysli Metref (etienne-dysli-metref) wrote :

Patch for focal copied from Debian buster's 3.0.4 security fix.

description: updated
summary: - Template generation allows external parameters to override placeholders
+ Phishing vulnerability: Template generation allows external parameters
+ to override placeholders
Mathew Hodson (mhodson)
Changed in shibboleth-sp (Ubuntu):
importance: Undecided → Medium
Changed in shibboleth-sp (Debian):
status: Confirmed → Fix Released
Revision history for this message
Etienne Dysli Metref (etienne-dysli-metref) wrote :

Assigned CVE: 2021-28963
https://security-tracker.debian.org/tracker/CVE-2021-28963

For some reason, the "link to CVE" on the right rejects "2021-28963"...

Revision history for this message
Etienne Dysli Metref (etienne-dysli-metref) wrote :

Is there something missing from the proposed patch?

Revision history for this message
Steve Beattie (sbeattie) wrote :

Hey Etienne,

Thanks for submitting the debdiff. I'm taking a look in more detail, but on first glance it looks good to me. If all goes well, I'll push it up to our security-proposed in a bit.

Changed in shibboleth-sp (Ubuntu):
assignee: nobody → Steve Beattie (sbeattie)
Revision history for this message
Steve Beattie (sbeattie) wrote :

I have pushed the focal update to the security-proposed ppa at https://launchpad.net/~ubuntu-security-proposed/+archive/ubuntu/ppa/+packages ; any testing that anyone could give once it is done building would be appreciated.

Thanks!

Steve Beattie (sbeattie)
Changed in shibboleth-sp (Ubuntu):
status: New → In Progress
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package shibboleth-sp - 3.0.4+dfsg1-1ubuntu0.1

---------------
shibboleth-sp (3.0.4+dfsg1-1ubuntu0.1) focal-security; urgency=high

  * SECURITY UPDATE: Fix a phishing vulnerability: Template generation
    allows external parameters to override placeholders (LP: #1919419)
    - debian/patches/SSPCPP-922-Add-externalParameters-option-to-Errors-
      element.patch: Add externalParameters option to Errors element
    - https://shibboleth.net/community/advisories/secadv_20210317.txt
    - https://issues.shibboleth.net/jira/browse/SSPCPP-922
    - CVE-2021-28963

 -- Etienne Dysli Metref <email address hidden> Thu, 18 Mar 2021 12:22:53 +0100

Changed in shibboleth-sp (Ubuntu):
status: In Progress → Fix Released
To post a comment you must log in.
This report contains Public Security information  
Everyone can see this security related information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.