Documentation ¶
Index ¶
- Constants
- func AssumeAWSRole(assertion, roleArn, principalArn string, duration int) (*sts.AssumeRoleWithSAMLOutput, error)
- func GetLastpassIdentitySession(session *http.Client) error
- func HomeDir() string
- func Login(session *http.Client, username, password, otp string) error
- func PromptForRole(roles [][]string) []string
- func SamlRoles(assertion string) [][]string
- func SamlToken(session *http.Client, samlURL string) (string, error)
- func SetAWSProfile(profileName string, response *sts.AssumeRoleWithSAMLOutput)
Constants ¶
View Source
const LastPassServer = "https://lastpass.com"
LastPassServer points to the Lastpass Server
Variables ¶
This section is empty.
Functions ¶
func AssumeAWSRole ¶
func AssumeAWSRole(assertion, roleArn, principalArn string, duration int) (*sts.AssumeRoleWithSAMLOutput, error)
AssumeAWSRole returns a response from assuming a role on AWS STS and includes the required credentials
func GetLastpassIdentitySession ¶
GetLastpassIdentitySession returns true if identity session is created
func Login ¶
Login will submit the credentials to LastPass to login and create the session for future use
func PromptForRole ¶
PromptForRole asks the user to choose a role if there are multiple
func SetAWSProfile ¶
func SetAWSProfile(profileName string, response *sts.AssumeRoleWithSAMLOutput)
SetAWSProfile saves the role credentials into ~/.aws/credentials
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.