mirror of
https://github.com/sirtoobii/vaultwarden_ldap_sync.git
synced 2026-04-26 20:45:54 +03:00
[GH-ISSUE #9] HTTP request to Vaultwarden API fails #7
Labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/vaultwarden_ldap_sync#7
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @mi-skam on GitHub (Nov 5, 2024).
Original GitHub issue: https://github.com/sirtoobii/vaultwarden_ldap_sync/issues/9
The startup of the service fails right at the API call of Vaultwarden. I double-checked the ADMIN_TOKENs correctness, so Im not sure what else to try.
Debug-Log from Portainer
2024-11-05:18:24:50 WARNING [LdapConnector.py] One of returned objects missing your LDAP_EMAIL_ATTR
2024-11-05:18:24:50 DEBUG [LdapConnector.py] LDAP request object returned following keys: dict_keys(['objectClass', 'cn', 'sn', 'givenName', 'distinguishedName', 'instanceType', 'whenCreated', 'whenChanged', 'displayName', 'uSNCreated', 'memberOf', 'uSNChanged', 'name', 'objectGUID', 'userAccountControl', 'codePage', 'countryCode', 'homeDirectory', 'homeDrive', 'pwdLastSet', 'primaryGroupID', 'profilePath', 'objectSid', 'accountExpires', 'sAMAccountName', 'sAMAccountType', 'userPrincipalName', 'objectCategory', 'dSCorePropagationData', 'lastLogonTimestamp'])
2024-11-05:18:24:50 WARNING [LdapConnector.py] One of returned objects missing your LDAP_EMAIL_ATTR
2024-11-05:18:24:50 DEBUG [LdapConnector.py] LDAP request object returned following keys: dict_keys(['objectClass', 'cn', 'sn', 'userCertificate', 'givenName', 'initials', 'distinguishedName', 'instanceType', 'whenCreated', 'whenChanged', 'displayName', 'uSNCreated', 'uSNChanged', 'company', 'name', 'objectGUID', 'userAccountControl', 'codePage', 'countryCode', 'homeDirectory', 'homeDrive', 'pwdLastSet', 'primaryGroupID', 'profilePath', 'objectSid', 'accountExpires', 'sAMAccountName', 'sAMAccountType', 'userPrincipalName', 'lockoutTime', 'objectCategory', 'dSCorePropagationData', 'lastLogonTimestamp', 'msExchUMDtmfMap', 'msExchRecipientSoftDeletedStatus', 'msExchPreviousRecipientTypeDetails', 'msExchWhenMailboxCreated', 'msExchDelegateListBL'])
2024-11-05:18:24:50 WARNING [LdapConnector.py] One of returned objects missing your LDAP_EMAIL_ATTR
2024-11-05:18:24:50 DEBUG [LdapConnector.py] LDAP request object returned following keys: dict_keys(['objectClass', 'cn', 'sn', 'userCertificate', 'givenName', 'initials', 'distinguishedName', 'instanceType', 'whenCreated', 'whenChanged', 'displayName', 'uSNCreated', 'uSNChanged', 'company', 'name', 'objectGUID', 'userAccountControl', 'codePage', 'countryCode', 'homeDirectory', 'homeDrive', 'pwdLastSet', 'primaryGroupID', 'profilePath', 'objectSid', 'accountExpires', 'sAMAccountName', 'sAMAccountType', 'userPrincipalName', 'lockoutTime', 'objectCategory', 'dSCorePropagationData', 'lastLogonTimestamp', 'msExchUMDtmfMap', 'msExchRecipientSoftDeletedStatus', 'msExchPreviousRecipientTypeDetails', 'msExchWhenMailboxCreated', 'msExchDelegateListBL'])
2024-11-05:18:24:50 WARNING [LdapConnector.py] One of returned objects missing your LDAP_EMAIL_ATTR
2024-11-05:18:24:50 DEBUG [LdapConnector.py] LDAP request object returned following keys: dict_keys(['objectClass', 'cn', 'sn', 'userCertificate', 'givenName', 'distinguishedName', 'instanceType', 'whenCreated', 'whenChanged', 'displayName', 'uSNCreated', 'uSNChanged', 'company', 'name', 'objectGUID', 'userAccountControl', 'codePage', 'countryCode', 'homeDirectory', 'homeDrive', 'pwdLastSet', 'primaryGroupID', 'objectSid', 'accountExpires', 'sAMAccountName', 'sAMAccountType', 'userPrincipalName', 'lockoutTime', 'objectCategory', 'dSCorePropagationData', 'lastLogonTimestamp', 'msExchUMDtmfMap', 'msExchRecipientSoftDeletedStatus', 'msExchPreviousRecipientTypeDetails', 'msExchWhenMailboxCreated'])
2024-11-05:18:24:50 WARNING [LdapConnector.py] One of returned objects missing your LDAP_EMAIL_ATTR
2024-11-05:18:24:50 DEBUG [LdapConnector.py] LDAP request object returned following keys: dict_keys(['objectClass', 'cn', 'sn', 'givenName', 'distinguishedName', 'instanceType', 'whenCreated', 'whenChanged', 'displayName', 'uSNCreated', 'memberOf', 'uSNChanged', 'name', 'objectGUID', 'userAccountControl', 'codePage', 'countryCode', 'pwdLastSet', 'primaryGroupID', 'objectSid', 'accountExpires', 'sAMAccountName', 'sAMAccountType', 'userPrincipalName', 'objectCategory', 'dSCorePropagationData'])
2024-11-05:18:24:50 INFO [sync.py] Starting...
2024-11-05:18:24:50 INFO [sync.py] DRYRUN: True
2024-11-05:18:24:50 INFO [sync.py] LDAP server: LDAPSERVER
2024-11-05:18:24:50 INFO [sync.py] Vaultwarden url: PUBLIC-URL
2024-11-05:18:24:50 DEBUG [connectionpool.py] Starting new HTTPS connection (1): PUBLIC-URL:443
2024-11-05:18:24:50 DEBUG [connectionpool.py] https://PUBLIC-URL:443 "GET /admin/users HTTP/11" 404 None
2024-11-05:18:24:50 ERROR [sync.py] Something went wrong. Error: Request returned unexpected return code expected: 200 actual: 404
@mi-skam commented on GitHub (Nov 5, 2024):
UPDATE: I had a typo in a env variable. Now one step further.
@sirtoobii commented on GitHub (Nov 5, 2024):
PUBLIC_URLis most likely not a resolvable domain name ;)@mi-skam commented on GitHub (Nov 5, 2024):
Of course not :)
@sirtoobii commented on GitHub (Nov 5, 2024):
Got it - this is just to not disclose information - but anyways, the token seems to be alright (hence the line
Authentication using token successful, storing cookie) however, further attempts fail.What version of Vaultwarden are you using?
@mi-skam commented on GitHub (Nov 5, 2024):
Exactly, :) Well, it's this Docker image:
vaultwarden/server:1.32.0-alpine@mi-skam commented on GitHub (Nov 5, 2024):
Here is my Stack:
@mi-skam commented on GitHub (Nov 6, 2024):
Ha! I found the issue, with the help of the debugger:
In my
.envfile I had a trailing slash in my definition, something likeVAULTWARDEN_URL=https://public.url/, changing it to ``VAULTWARDEN_URL=https://public.url` seems to work 🎉