ListAtRevision
Retrieves a list of HBA rules for Greenplum clusters for particular revision.
- TypeScript
- Python
import { cloudApi, serviceClients, Session } from "@yandex-cloud/nodejs-sdk";
const ListHBARulesAtRevisionRequest =
cloudApi.mdb.greenplum_hba_rule_service.ListHBARulesAtRevisionRequest;
(async () => {
const authToken = process.env["YC_OAUTH_TOKEN"];
const session = new Session({ oauthToken: authToken });
const client = session.client(serviceClients.HBARuleServiceClient);
const result = await client.listAtRevision(
ListHBARulesAtRevisionRequest.fromPartial({
clusterId: "clusterId",
// revision: 0
})
);
console.log(result);
})();
import os
import grpc
import yandexcloud
from yandex.cloud.mdb.greenplum.v1.hba_rule_service_pb2_grpc import HBARuleServiceStub
from yandex.cloud.mdb.greenplum.v1.hba_rule_service_pb2 import ListHBARulesAtRevisionRequest
token = os.getenv("YC_OAUTH_TOKEN")
sdk = yandexcloud.SDK(token=token)
service = sdk.client(HBARuleServiceStub)
response = service.ListAtRevision(
ListHBARulesAtRevisionRequest(
cluster_id="clusterId",
# revision = 0
)
)
print(response)
ListHBARulesAtRevisionRequest
clusterId
: string
ID of the Greenplum cluster. To get the Greenplum cluster ID use a ClusterService.List request.
revision
: int64
Cluster revision
ListHBARulesResponse
hbaRules
: HBARule
Requested list of hba rules for the cluster.
HBARule
ConnectionType
CONNECTION_TYPE_UNSPECIFIED
HOST
Matches connection attempts made using TCP/IP.
HOSTSSL
Matches connection attempts made using TCP/IP, but only when the connection is made with SSL encryption.
HOSTNOSSL
Matches connection attempts made over TCP/IP that do not use SSL.
AuthMethod
AUTH_METHOD_UNSPECIFIED
MD5
Perform SCRAM-SHA-256 or MD5 authentication to verify the user's password.
LDAP
Perform LDAP authentication, if MDB_GREENPLUM_LDAP flag is set
REJECT
Disable authentication
priority
: int64
Priority of the Greenplum cluster rule.
connectionType
: ConnectionType
database
: string
Specifies which database names this record matches.
user
: string
Specifies which database role names this user matches.
address
: string
Specifies the client machine addresses that this record matches.
authMethod
: AuthMethod
Specifies the authentication method to use when a connection matches this record. https://gpdb.docs.pivotal.io/6-6/security-guide/topics/Authenticate.html