mirror of
https://github.com/Garmelon/PFERD.git
synced 2026-04-12 15:35:05 +02:00
adapted shibboleth login for FAU (slightly different POST url and payload)
This commit is contained in:
parent
2c22794c69
commit
ac7bf13656
1 changed files with 7 additions and 8 deletions
|
|
@ -60,16 +60,15 @@ class FauShibbolethLogin:
|
|||
|
||||
# Equivalent: Enter credentials in
|
||||
# https://idp.scc.kit.edu/idp/profile/SAML2/Redirect/SSO
|
||||
url = str(shib_url.origin()) + action
|
||||
if action.startswith("https"): # FAU uses full URL here
|
||||
url = action
|
||||
else:
|
||||
url = str(shib_url.origin()) + action #KIT uses relative URL here
|
||||
username, password = await self._auth.credentials()
|
||||
data = {
|
||||
"_eventId_proceed": "",
|
||||
"j_username": username,
|
||||
"j_password": password,
|
||||
"fudis_web_authn_assertion_input": "",
|
||||
"username": username,
|
||||
"password": password
|
||||
}
|
||||
if csrf_token_input := form.find("input", {"name": "csrf_token"}):
|
||||
data["csrf_token"] = csrf_token_input["value"] # type: ignore
|
||||
soup = await _post(sess, url, data)
|
||||
|
||||
if soup.find(id="attributeRelease"):
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue