com.aliyuncs.v5.auth.KeyPairCredentials Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of aliyun-java-sdk-core-v5 Show documentation
Show all versions of aliyun-java-sdk-core-v5 Show documentation
Aliyun Open API SDK for Java
Copyright (C) Alibaba Cloud Computing
All rights reserved.
版权所有 (C)阿里云计算有限公司
http://www.aliyun.com
The newest version!
package com.aliyuncs.v5.auth;
public class KeyPairCredentials implements AlibabaCloudCredentials {
private String privateKeySecret;
private String publicKeyId;
public KeyPairCredentials(String publicKeyId, String privateKeySecret) {
if (publicKeyId == null || privateKeySecret == null) {
throw new IllegalArgumentException(
"You must provide a valid pair of Public Key ID and Private Key Secret.");
}
this.publicKeyId = publicKeyId;
this.privateKeySecret = privateKeySecret;
}
@Override
public String getAccessKeyId() {
return publicKeyId;
}
@Override
public String getAccessKeySecret() {
return privateKeySecret;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy