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

Web based Cognito authentication for Nucleus Airflow UI #123

Closed
ramesh-maddegoda opened this issue Oct 3, 2024 · 16 comments
Closed

Web based Cognito authentication for Nucleus Airflow UI #123

ramesh-maddegoda opened this issue Oct 3, 2024 · 16 comments

Comments

@ramesh-maddegoda
Copy link
Contributor

ramesh-maddegoda commented Oct 3, 2024

💡 Description

As a part of the ticket Setup role based authentication and authorization for Airflow UI with Cognito, an ALB based approach to enable Cognito authentication for Nucleus Airflow UI was implemented. However, the ALB based approach only worked sometimes and currently there is an Amazon support ticket Case 172781777100323 to troubleshoot it. At the moment, a python script is used to get a web token URL to access Airflow UI.

This ticket is created to focus on resolving this ALB related problem and eventually implement web based Cognito authentication for Nucleus Airflow UI.

⚔️ Parent Epic / Related Tickets

Related: Setup role based authentication and authorization for Airflow UI with Cognito

@ramesh-maddegoda ramesh-maddegoda self-assigned this Oct 3, 2024
@github-project-automation github-project-automation bot moved this to Release Backlog in B15.1 Oct 3, 2024
@ramesh-maddegoda ramesh-maddegoda changed the title web based Cognito authentication for Nucleus Airflow UI Web based Cognito authentication for Nucleus Airflow UI Oct 3, 2024
@tloubrieu-jpl
Copy link
Member

Ramesh needs the access log of the EC2 application load balancer to be set to investigate an issue with the web authentication for nucleus. Rmesh will send a ticket to MCP if it does not go through.

@ramesh-maddegoda
Copy link
Contributor Author

It seems, there is a permission issues in MCP. I created the ticket GSD-4269

@tloubrieu-jpl
Copy link
Member

The MCP ticket has been assigned to someone who is going to help investigate the issue.

@tloubrieu-jpl
Copy link
Member

@ramesh-maddegoda was able to unblock this issue by having the log enabled. He will move forward now with this task.

@jordanpadams jordanpadams added enhancement New feature or request theme and removed task labels Oct 31, 2024
@jordanpadams jordanpadams moved this from Release Backlog to Blocked in B15.1 Oct 31, 2024
@jordanpadams jordanpadams added Epic p.must-have and removed enhancement New feature or request labels Oct 31, 2024
@tloubrieu-jpl
Copy link
Member

The AWS ticket is escalated to the Cognito team.

@tloubrieu-jpl
Copy link
Member

Network rules (NACL) must be updated for that to work.

@jordanpadams
Copy link
Member

📆 10/2024 status: in work on schedule

@tloubrieu-jpl
Copy link
Member

@ramesh-maddegoda made tests which show that the network is properly configured. He is now investigating possible issues with the Gognito UI redirect URLs.

@tloubrieu-jpl
Copy link
Member

In progress

@jordanpadams
Copy link
Member

📆 11/2024 status: Delayed waiting input from AWS do to intermittent issues during authentication process. No impact on other tasks.

@jordanpadams
Copy link
Member

Status: Ticket in MCP has moved to implementation.

@tloubrieu-jpl
Copy link
Member

MCP fixed the network rules following AWS recommendation.

One error remains because of a wrong architecture depedency (mac vs x86).

@ramesh-maddegoda
Copy link
Contributor Author

Implemented the MWAA COgnito login as explained in the following sites.

Application load balancer single-sign-on for Amazon MWAA
Accessing a private Amazon MWAA environment using federated identities
When I accessed this ALB and Lambda Based Cognito login to MWAA Airflow UI, it creates a new user in Airflow list of users every time.

Created the following bug to fix this.
#136

@ramesh-maddegoda
Copy link
Contributor Author

The Cognito token validation should be implemented as a remaining task.

@tloubrieu-jpl
Copy link
Member

@ramesh-maddegoda found a python library (joss) to validate the JWT token. He is now terraforming the configuration and cleaning the code before making making a PR.

@tloubrieu-jpl
Copy link
Member

90% of terraforming the update using cognito.

RDS Aurora disappeared from MCP which breaks the existing deployment.
@ramesh-maddegoda replaced it with something else.

ramesh-maddegoda added a commit that referenced this issue Feb 4, 2025
…Cognito auth and web token based approach

Refer to issue: #123
ramesh-maddegoda added a commit that referenced this issue Feb 4, 2025
…Cognito auth and web token based approach

Refer to issue: #123
ramesh-maddegoda added a commit that referenced this issue Feb 4, 2025
Refer to issue: #123
ramesh-maddegoda added a commit that referenced this issue Feb 5, 2025
…n period for pds_nucleus_auth_alb cloud watch group.

Refer to issue: #123
ramesh-maddegoda added a commit that referenced this issue Feb 5, 2025
…gging for pds_nucleus_auth_alb_logs bucket for additional audit trails as per SonarQube suggestions.

Refer to issue: #123
ramesh-maddegoda added a commit that referenced this issue Feb 5, 2025
…DATE the code with code quality improvements.

Refer to issue: #123
@github-project-automation github-project-automation bot moved this from Blocked to 🏁 Done in B15.1 Feb 6, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: 🏁 Done
Development

No branches or pull requests

3 participants