Skip to content
This repository was archived by the owner on Jul 21, 2025. It is now read-only.

Conversation

@akshay-online
Copy link
Collaborator

This pull request introduces several changes to the ADOGenerator project, including the addition of new services, modifications to existing interfaces, and enhancements to the authentication process. The most important changes are grouped by theme below:

New Services and Interfaces:

  • Added IAuthService interface with methods for acquiring tokens, getting profile information, and selecting organizations (src/ADOGenerator/IServices/IAuthService.cs).
  • Added IInitService interface with methods for extracting links, reading secrets, printing error messages, and checking project names (src/ADOGenerator/IServices/IInitService.cs).

Dependency Updates:

  • Added Microsoft.Identity.Client package reference to the project file ADOGenerator.csproj to support Azure AD authentication (src/ADOGenerator/ADOGenerator.csproj).

Authentication Enhancements:

  • Implemented authentication options in Program.cs for users to choose between device login using AD auth or Personal Access Token (PAT) (src/ADOGenerator/Program.cs). [1] [2] [3]

Interface Modifications:

  • Changed the return type of CreateProjectEnvironment method in IProjectService interface from string[] to bool (src/ADOGenerator/IServices/IProjectService.cs).

Project Model Update:

  • Added adoAuthScheme property to the Project class to store the authentication scheme used (src/ADOGenerator/Models/Project.cs).

akshay-online and others added 5 commits December 3, 2024 17:57
Refactored `TryGetTemplateDetails` in `Program.cs` by removing its detailed implementation while keeping the method signature intact. Updated `AuthService.cs` to initialize `clientId`, `tenantId`, and `scopes` from `appsettings.json` using a static constructor, making these values configurable. Added new configuration settings for `clientId`, `tenantId`, and `scopes` in `appsettings.json`. Removed unused Azure DevOps project fetching code from `AuthService.cs`.
Add documentation for Device Code Flow authentication in Azure AD
@akshay-online akshay-online merged commit a04bd9a into main Dec 10, 2024
3 checks passed
@akshay-online akshay-online deleted the aksh/adding-AD-Auth branch December 10, 2024 11:41
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants