Skip to content
This repository has been archived by the owner on Sep 7, 2024. It is now read-only.

Add case insensitive option to config file #6

Open
oxr463 opened this issue Oct 8, 2021 · 0 comments
Open

Add case insensitive option to config file #6

oxr463 opened this issue Oct 8, 2021 · 0 comments
Labels
enhancement New feature or request
Milestone

Comments

@oxr463
Copy link
Contributor

oxr463 commented Oct 8, 2021

STATIC int verify_user(jwt_t * jwt, const char *username)
{
    const char *upn = jwt_get_grant(jwt, "upn");
    return (strcmp(upn, username) == 0) ? EXIT_SUCCESS : EXIT_FAILURE;
}

We are accepting input from two sources without normalizing either. I.E. if John Doe was in AAD as [email protected] he would have to auth via a service with Jdoe instead of being able to use jdoe. The strcmp will fail every time due to this even though the user exists and is valid. Will push a PR to fix.

Source: CyberNinjas/pam_aad#55

@oxr463 oxr463 added the enhancement New feature or request label Oct 8, 2021
@oxr463 oxr463 added this to the v1.0.0 milestone Oct 8, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant