-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add test workflow for testing MSAL Authentication
- Loading branch information
Showing
1 changed file
with
71 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
name: MSAL Federated Credentials | ||
Check warning on line 1 in .github/workflows/msidp-authentication-test.yml GitHub Actions / Node.js / PrettierCode style issues found in '.github/workflows/msidp-authentication-test.yml'
|
||
|
||
on: | ||
workflow_dispatch: | ||
inputs: | ||
tenant-id: | ||
type: string | ||
required: true | ||
client-id: | ||
type: string | ||
required: true | ||
resource: | ||
type: string | ||
resource-hostname: | ||
type: string | ||
|
||
permissions: | ||
id-token: write | ||
|
||
jobs: | ||
msal: | ||
name: Acquire Azure AD Access Token | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout ${{ github.repository }}@${{ github.ref }} | ||
uses: actions/checkout@v4.1.1 | ||
- name: Authenticate using GitHub action | ||
uses: ./run/ms-idp-workflow-run-auth | ||
with: | ||
tenant-id: ${{ inputs.tenant-id }} | ||
client-id: ${{ inputs.client-id }} | ||
resource: ${{ inputs.resource }} | ||
msal-tmp-cert: | ||
name: Acquire Azure AD Access Token (using temporary certificate) | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout ${{ github.repository }}@${{ github.ref }} | ||
uses: actions/checkout@v4.1.1 | ||
- name: Authenticate using GitHub action | ||
uses: ./run/ms-idp-workflow-run-auth | ||
with: | ||
tenant-id: ${{ inputs.tenant-id }} | ||
client-id: ${{ inputs.client-id }} | ||
resource: ${{ inputs.resource }} | ||
auth-method: 'ms-idp-temporary-certificate' | ||
msal-tmp-secret: | ||
name: Acquire Azure AD Access Token (using temporary secret) | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout ${{ github.repository }}@${{ github.ref }} | ||
uses: actions/checkout@v4.1.1 | ||
- name: Authenticate using GitHub action | ||
uses: ./run/ms-idp-workflow-run-auth | ||
with: | ||
tenant-id: ${{ inputs.tenant-id }} | ||
client-id: ${{ inputs.client-id }} | ||
resource: ${{ inputs.resource }} | ||
auth-method: 'ms-idp-temporary-secret' | ||
acs-tmp-secret: | ||
name: Acquire Azure AD Access Token (using ACS with temporary secret) | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout ${{ github.repository }}@${{ github.ref }} | ||
uses: actions/checkout@v4.1.1 | ||
- name: Authenticate using GitHub action | ||
uses: ./run/ms-idp-workflow-run-auth | ||
with: | ||
tenant-id: ${{ inputs.tenant-id }} | ||
client-id: ${{ inputs.client-id }} | ||
resource: ${{ inputs.resource }}/${{ inputs.resource-hostname }} | ||
auth-method: 'az-acs-temporary-secret' |