mirror of
https://github.com/actions/toolkit.git
synced 2026-08-13 00:00:44 +02:00
Full release of actions/core 1.6.0 with oidc behavior (#919)
* OIDC Client for actions/core Co-authored-by: Sourav Chanduka <[email protected]> Co-authored-by: Sourav Chanduka <[email protected]> Co-authored-by: Tingluo Huang <[email protected]>
This commit is contained in:
co-authored by
Sourav Chanduka
Sourav Chanduka
Tingluo Huang
parent
60145e408c
commit
27f76dfe1a
@@ -5,6 +5,8 @@ import {toCommandProperties, toCommandValue} from './utils'
|
||||
import * as os from 'os'
|
||||
import * as path from 'path'
|
||||
|
||||
import {OidcClient} from './oidc-utils'
|
||||
|
||||
/**
|
||||
* Interface for getInput options
|
||||
*/
|
||||
@@ -353,3 +355,7 @@ export function saveState(name: string, value: any): void {
|
||||
export function getState(name: string): string {
|
||||
return process.env[`STATE_${name}`] || ''
|
||||
}
|
||||
|
||||
export async function getIDToken(aud?: string): Promise<string> {
|
||||
return await OidcClient.getIDToken(aud)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user