Details
-
Bug
-
Status: Closed (View Workflow)
-
P2
-
Resolution: Done
-
None
-
None
-
-
CP: sprint 88, CP: sprint 89, CP: R3 2022 roadmap
-
5
-
Core: Platform
Description
Impact
An attacker can associate their FOLIO account with a victim’s session on the FOLIO application. This could result in a victim unknowingly using an attacker’s FOLIO account while interacting with the application.
Description
The FOLIO application does not employ any mechanism to prevent CSRF attacks in the SSO flow. The first endpoint on the application accepts the SAMLResponse parameter, sets a session ID on the client and redirects the user to the second endpoint which retrieves the JWT from the query parameters to interact with the API endpoints. A user of the FOLIO application can submit personal and potentially sensitive information related to patrons, tenants and libraries to the application. As a result, the attacker would be able to observe all activities through their own FOLIO account. It should be noted that both of the target endpoints can be used to perform a CSRF attack during the SSO flow.
Repro steps
1. Log in to the application using an attacker’s account with SSO enabled. Intercept the request to the SSO endpoint (the first endpoint in the Location section) on the application, copy the request and drop it afterwards.
2. Browse to the previously copied URL in a new browser instance with cleared cookies and observe the login flow completes successfully.
1. Obtain a valid token from an attacker account and open the following URL (with the value of ssoToken replaced by the obtained token) in a new browser session:
https://bugfest.folio.ebsco.com/sso- landing?ssoToken=eyJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJhZG1p biIsInVzZXJfaWQiOiJhMDU4ZjI4Zi04MGFjLTQ5OTQtYWRkNi1lNGQwMmZjMjM4ZmUiLCJpYXQi OjE1ODIyMzE1MjMsInRlbmFudCI6ImZzMDAwMDEwMDAifQ.u4xRSZQnE1PjiYttQSNVd3JJ_Su44 zOQRu2dprnQ67U&fwd=%2F
Recomendation
Ensure that a state parameter similar to OAuth 2.0 state parameter is utilized to maintain the state between the Idp and the application . The state parameter should be used to protect the clients by passing a unique, securely generated random string as the value of the parameter when redirecting a user to the callback endpoint on the application. For more information on this, refer to RFC6749.
TestRail: Results
Attachments
Issue Links
- blocks
-
MODLOGSAML-65 Create mod-login-saml security release
-
- Closed
-
- is blocked by
-
MODLOGSAML-63 Implement CSRF Prevention
-
- Closed
-
-
OKAPI-847 Conditionally defer CORS handling to module when invoked via passthrough API
-
- Closed
-
-
OKAPI-876 CORS delegation doesn't work with preflight/OPTIONS requests
-
- Closed
-
-
STCOR-544 Set credentials: include on fetch to /saml/login
-
- Closed
-
- relates to
-
FOLIO-2524 Security Audit raised issues
-
- Open
-
-
MODLOGSAML-58 Arbitrary URL Redirection in SAML Response
-
- Closed
-
-
STCOR-740 JWT Token should not be stored in localstorage
-
- Closed
-
- mentioned in
-
Page Loading...