Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AUP exemption #811

Open
wants to merge 30 commits into
base: develop
Choose a base branch
from
Open

AUP exemption #811

wants to merge 30 commits into from

Conversation

garaimanoj
Copy link
Contributor

No description provided.

@garaimanoj garaimanoj changed the base branch from master to develop July 22, 2024 14:50
@garaimanoj garaimanoj self-assigned this Jul 22, 2024
@garaimanoj garaimanoj linked an issue Jul 22, 2024 that may be closed by this pull request
@enricovianello enricovianello added status/in-progress component/db Issue that includes one or more db migrations labels Aug 7, 2024
@garaimanoj garaimanoj marked this pull request as ready for review August 16, 2024 12:57
@garaimanoj garaimanoj requested a review from rmiccoli August 19, 2024 14:26
Copy link
Contributor

@rmiccoli rmiccoli left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In general, the PR looks good to me.

I have only some comments:

  • would it be better to handle the IamAupSignatureUpdateError exception and print the error message? now only the status code 405 is shown
  • if the user is set up as a service account after having already signed the AUP, does it make sense to set the AUP signature time to null? this should not even trigger the AUP expiry reminder emails

@enricovianello
Copy link
Member

  • would it be better to handle the IamAupSignatureUpdateError exception and print the error message? now only the status code 405 is shown

I agree, we could add an ExceptionHandler like this in the same controller this https://github.com/indigo-iam/iam/pull/811/files#diff-a8bc81ad573d8d00f0b71699cc5862722f1bc38abdd3c9cd03e206639a9f904aR205-R209

  • if the user is set up as a service account after having already signed the AUP, does it make sense to set the AUP signature time to null? this should not even trigger the AUP expiry reminder emails

It makes sense to me. In my opinion when the administrator is prompted with the message of "service account creation" it should be aware of the fact that this account will lose the signatures and it will be exempted from them in the future. Again, as soon as the admin is going to switch again from a service account to a "normal" one, we could be very clear in the message by explaining that the user won't have any signature so he can decide to sign it on behalf in case.
I also prefer that the AUP reminder logic is updated with a filter that excludes service account when it looks for the accounts that have to receive the email.

@garaimanoj
Copy link
Contributor Author

garaimanoj commented Aug 20, 2024

In my opinion when the administrator is prompted with the message of "service account creation" it should be aware of the fact that this account will lose the signatures and it will be exempted from them in the future. Again, as soon as the admin is going to switch again from a service account to a "normal" one, we could be very clear in the message by explaining that the user won't have any signature so he can decide to sign it on behalf in case.

We had a discussion regarding deletion of existing AUP signature. During that @enricovianello mentioned that if Admin by mistake set the account as service account then we will loose the AUP signature. So we can keep the signature as is and when account will be back as normal account we can have all the signature data as is.

I think checking the service account status check during AUP reminder is a good idea. If all agree I could add that additional check.

@rmiccoli
Copy link
Contributor

rmiccoli commented Aug 20, 2024

When the account is set up as a service account, the signature of the aup is skipped (if it is defined), but what if it accidentally goes to the /iam/aup/sign endpoint and accepts the aup? the exception is thrown at this time, I don't know if the ExceptionHandler should be added here as well

public ModelAndView signAup(HttpServletRequest request, HttpServletResponse response,

@garaimanoj
Copy link
Contributor Author

When the account is set up as a service account, the signature of the aup is skipped (if it is defined), but what if it accidentally goes to the /iam/aup/sign endpoint and accepts the aup? the exception is thrown at this time, I don't know if the ExceptionHandler should be added here as well

public ModelAndView signAup(HttpServletRequest request, HttpServletResponse response,

I am going to add the exception handler and a test.

@garaimanoj garaimanoj requested a review from rmiccoli August 21, 2024 10:57
@garaimanoj garaimanoj requested a review from rmiccoli September 3, 2024 10:09
@rmiccoli rmiccoli changed the title Issue 737 aup exemption AUP exemption Sep 3, 2024
Copy link
Member

@enricovianello enricovianello left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If we add things to SCIM user that are not in the SCIM protocol we need to add them inside ScimIndigoUser extension object

@rmiccoli rmiccoli force-pushed the issue-737-aup-exemption branch from cd38727 to a48620e Compare December 17, 2024 16:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component/db Issue that includes one or more db migrations kind/feature status/done
Projects
None yet
Development

Successfully merging this pull request may close these issues.

The AUP requirement should be configurable per account
3 participants