public StaticCredentialsProvider(IClientProfile clientProfile)
        {
            this.clientProfile = clientProfile;
            StsCredential legacyCredential = this.clientProfile.GetCredential();

            if (null != legacyCredential.SecurityToken)
            {
                credentials = new BasicSessionCredentials(
                    legacyCredential.AccessKeyId,
                    legacyCredential.AccessSecret,
                    legacyCredential.SecurityToken);
            }
            else
            {
                credentials = new LegacyCredentials(legacyCredential);
            }
        }
Esempio n. 2
0
 public LegacyCredentials(StsCredential legacyCrendential)
 {
     this.legacyCredential = legacyCrendential;
 }