Network Security API provides resources to configure authentication and authorization policies.
Refer to per API resource documentation for more information.
Equality
Instances of this class created via copy-construction or copy-assignment always compare equal. Instances created with equal std::shared_ptr<*Connection>
objects compare equal. Objects that compare equal share the same underlying resources.
Performance
Creating a new instance of this class is a relatively expensive operation, new objects establish new connections to the service. In contrast, copy-construction, move-construction, and the corresponding assignment operations are relatively efficient as the copies share all underlying resources.
Thread Safety
Concurrent access to different instances of this class, even if they compare equal, is guaranteed to work. Two or more threads operating on the same instance of this class is not guaranteed to work. Since copy-construction and move-construction is a relatively efficient operation, consider using such a copy when using this class from multiple threads.
Constructors
NetworkSecurityClient(NetworkSecurityClient const &)
Copy and move support
Parameter | |
---|---|
Name | Description |
|
NetworkSecurityClient const &
|
NetworkSecurityClient(NetworkSecurityClient &&)
Copy and move support
Parameter | |
---|---|
Name | Description |
|
NetworkSecurityClient &&
|
NetworkSecurityClient(std::shared_ptr< NetworkSecurityConnection >, Options)
Parameters | |
---|---|
Name | Description |
connection |
std::shared_ptr< NetworkSecurityConnection >
|
opts |
Options
|
Operators
operator=(NetworkSecurityClient const &)
Copy and move support
Parameter | |
---|---|
Name | Description |
|
NetworkSecurityClient const &
|
Returns | |
---|---|
Type | Description |
NetworkSecurityClient & |
operator=(NetworkSecurityClient &&)
Copy and move support
Parameter | |
---|---|
Name | Description |
|
NetworkSecurityClient &&
|
Returns | |
---|---|
Type | Description |
NetworkSecurityClient & |
Functions
ListAuthorizationPolicies(std::string const &, Options)
Lists AuthorizationPolicies in a given project and location.
Parameters | |
---|---|
Name | Description |
parent |
std::string const &
Required. The project and location from which the AuthorizationPolicies should be listed, specified in the format |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
StreamRange< google::cloud::networksecurity::v1::AuthorizationPolicy > |
a StreamRange to iterate of the results. See the documentation of this type for details. In brief, this class has |
ListAuthorizationPolicies(google::cloud::networksecurity::v1::ListAuthorizationPoliciesRequest, Options)
Lists AuthorizationPolicies in a given project and location.
Parameters | |
---|---|
Name | Description |
request |
google::cloud::networksecurity::v1::ListAuthorizationPoliciesRequest
Unary RPCs, such as the one wrapped by this function, receive a single |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
StreamRange< google::cloud::networksecurity::v1::AuthorizationPolicy > |
a StreamRange to iterate of the results. See the documentation of this type for details. In brief, this class has |
GetAuthorizationPolicy(std::string const &, Options)
Gets details of a single AuthorizationPolicy.
Parameters | |
---|---|
Name | Description |
name |
std::string const &
Required. A name of the AuthorizationPolicy to get. Must be in the format |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
StatusOr< google::cloud::networksecurity::v1::AuthorizationPolicy > |
the result of the RPC. The response message type (google.cloud.networksecurity.v1.AuthorizationPolicy) is mapped to a C++ class using the Protobuf mapping rules. If the request fails, the |
GetAuthorizationPolicy(google::cloud::networksecurity::v1::GetAuthorizationPolicyRequest const &, Options)
Gets details of a single AuthorizationPolicy.
Parameters | |
---|---|
Name | Description |
request |
google::cloud::networksecurity::v1::GetAuthorizationPolicyRequest const &
Unary RPCs, such as the one wrapped by this function, receive a single |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
StatusOr< google::cloud::networksecurity::v1::AuthorizationPolicy > |
the result of the RPC. The response message type (google.cloud.networksecurity.v1.AuthorizationPolicy) is mapped to a C++ class using the Protobuf mapping rules. If the request fails, the |
CreateAuthorizationPolicy(std::string const &, google::cloud::networksecurity::v1::AuthorizationPolicy const &, std::string const &, Options)
Creates a new AuthorizationPolicy in a given project and location.
Parameters | |
---|---|
Name | Description |
parent |
std::string const &
Required. The parent resource of the AuthorizationPolicy. Must be in the format |
authorization_policy |
google::cloud::networksecurity::v1::AuthorizationPolicy const &
Required. AuthorizationPolicy resource to be created. |
authorization_policy_id |
std::string const &
Required. Short name of the AuthorizationPolicy resource to be created. This value should be 1-63 characters long, containing only letters, numbers, hyphens, and underscores, and should not start with a number. E.g. "authz_policy". |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
future< StatusOr< google::cloud::networksecurity::v1::AuthorizationPolicy > > |
A |
CreateAuthorizationPolicy(google::cloud::networksecurity::v1::CreateAuthorizationPolicyRequest const &, Options)
Creates a new AuthorizationPolicy in a given project and location.
Parameters | |
---|---|
Name | Description |
request |
google::cloud::networksecurity::v1::CreateAuthorizationPolicyRequest const &
Unary RPCs, such as the one wrapped by this function, receive a single |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
future< StatusOr< google::cloud::networksecurity::v1::AuthorizationPolicy > > |
A |
UpdateAuthorizationPolicy(google::cloud::networksecurity::v1::AuthorizationPolicy const &, google::protobuf::FieldMask const &, Options)
Updates the parameters of a single AuthorizationPolicy.
Parameters | |
---|---|
Name | Description |
authorization_policy |
google::cloud::networksecurity::v1::AuthorizationPolicy const &
Required. Updated AuthorizationPolicy resource. |
update_mask |
google::protobuf::FieldMask const &
Optional. Field mask is used to specify the fields to be overwritten in the AuthorizationPolicy resource by the update. The fields specified in the update_mask are relative to the resource, not the full request. A field will be overwritten if it is in the mask. If the user does not provide a mask then all fields will be overwritten. |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
future< StatusOr< google::cloud::networksecurity::v1::AuthorizationPolicy > > |
A |
UpdateAuthorizationPolicy(google::cloud::networksecurity::v1::UpdateAuthorizationPolicyRequest const &, Options)
Updates the parameters of a single AuthorizationPolicy.
Parameters | |
---|---|
Name | Description |
request |
google::cloud::networksecurity::v1::UpdateAuthorizationPolicyRequest const &
Unary RPCs, such as the one wrapped by this function, receive a single |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
future< StatusOr< google::cloud::networksecurity::v1::AuthorizationPolicy > > |
A |
DeleteAuthorizationPolicy(std::string const &, Options)
Deletes a single AuthorizationPolicy.
Parameters | |
---|---|
Name | Description |
name |
std::string const &
Required. A name of the AuthorizationPolicy to delete. Must be in the format |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
future< StatusOr< google::cloud::networksecurity::v1::OperationMetadata > > |
A |
DeleteAuthorizationPolicy(google::cloud::networksecurity::v1::DeleteAuthorizationPolicyRequest const &, Options)
Deletes a single AuthorizationPolicy.
Parameters | |
---|---|
Name | Description |
request |
google::cloud::networksecurity::v1::DeleteAuthorizationPolicyRequest const &
Unary RPCs, such as the one wrapped by this function, receive a single |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
future< StatusOr< google::cloud::networksecurity::v1::OperationMetadata > > |
A |
ListServerTlsPolicies(std::string const &, Options)
Lists ServerTlsPolicies in a given project and location.
Parameters | |
---|---|
Name | Description |
parent |
std::string const &
Required. The project and location from which the ServerTlsPolicies should be listed, specified in the format |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
StreamRange< google::cloud::networksecurity::v1::ServerTlsPolicy > |
a StreamRange to iterate of the results. See the documentation of this type for details. In brief, this class has |
ListServerTlsPolicies(google::cloud::networksecurity::v1::ListServerTlsPoliciesRequest, Options)
Lists ServerTlsPolicies in a given project and location.
Parameters | |
---|---|
Name | Description |
request |
google::cloud::networksecurity::v1::ListServerTlsPoliciesRequest
Unary RPCs, such as the one wrapped by this function, receive a single |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
StreamRange< google::cloud::networksecurity::v1::ServerTlsPolicy > |
a StreamRange to iterate of the results. See the documentation of this type for details. In brief, this class has |
GetServerTlsPolicy(std::string const &, Options)
Gets details of a single ServerTlsPolicy.
Parameters | |
---|---|
Name | Description |
name |
std::string const &
Required. A name of the ServerTlsPolicy to get. Must be in the format |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
StatusOr< google::cloud::networksecurity::v1::ServerTlsPolicy > |
the result of the RPC. The response message type (google.cloud.networksecurity.v1.ServerTlsPolicy) is mapped to a C++ class using the Protobuf mapping rules. If the request fails, the |
GetServerTlsPolicy(google::cloud::networksecurity::v1::GetServerTlsPolicyRequest const &, Options)
Gets details of a single ServerTlsPolicy.
Parameters | |
---|---|
Name | Description |
request |
google::cloud::networksecurity::v1::GetServerTlsPolicyRequest const &
Unary RPCs, such as the one wrapped by this function, receive a single |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
StatusOr< google::cloud::networksecurity::v1::ServerTlsPolicy > |
the result of the RPC. The response message type (google.cloud.networksecurity.v1.ServerTlsPolicy) is mapped to a C++ class using the Protobuf mapping rules. If the request fails, the |
CreateServerTlsPolicy(std::string const &, google::cloud::networksecurity::v1::ServerTlsPolicy const &, std::string const &, Options)
Creates a new ServerTlsPolicy in a given project and location.
Parameters | |
---|---|
Name | Description |
parent |
std::string const &
Required. The parent resource of the ServerTlsPolicy. Must be in the format |
server_tls_policy |
google::cloud::networksecurity::v1::ServerTlsPolicy const &
Required. ServerTlsPolicy resource to be created. |
server_tls_policy_id |
std::string const &
Required. Short name of the ServerTlsPolicy resource to be created. This value should be 1-63 characters long, containing only letters, numbers, hyphens, and underscores, and should not start with a number. E.g. "server_mtls_policy". |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
future< StatusOr< google::cloud::networksecurity::v1::ServerTlsPolicy > > |
A |
CreateServerTlsPolicy(google::cloud::networksecurity::v1::CreateServerTlsPolicyRequest const &, Options)
Creates a new ServerTlsPolicy in a given project and location.
Parameters | |
---|---|
Name | Description |
request |
google::cloud::networksecurity::v1::CreateServerTlsPolicyRequest const &
Unary RPCs, such as the one wrapped by this function, receive a single |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
future< StatusOr< google::cloud::networksecurity::v1::ServerTlsPolicy > > |
A |
UpdateServerTlsPolicy(google::cloud::networksecurity::v1::ServerTlsPolicy const &, google::protobuf::FieldMask const &, Options)
Updates the parameters of a single ServerTlsPolicy.
Parameters | |
---|---|
Name | Description |
server_tls_policy |
google::cloud::networksecurity::v1::ServerTlsPolicy const &
Required. Updated ServerTlsPolicy resource. |
update_mask |
google::protobuf::FieldMask const &
Optional. Field mask is used to specify the fields to be overwritten in the ServerTlsPolicy resource by the update. The fields specified in the update_mask are relative to the resource, not the full request. A field will be overwritten if it is in the mask. If the user does not provide a mask then all fields will be overwritten. |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
future< StatusOr< google::cloud::networksecurity::v1::ServerTlsPolicy > > |
A |
UpdateServerTlsPolicy(google::cloud::networksecurity::v1::UpdateServerTlsPolicyRequest const &, Options)
Updates the parameters of a single ServerTlsPolicy.
Parameters | |
---|---|
Name | Description |
request |
google::cloud::networksecurity::v1::UpdateServerTlsPolicyRequest const &
Unary RPCs, such as the one wrapped by this function, receive a single |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
future< StatusOr< google::cloud::networksecurity::v1::ServerTlsPolicy > > |
A |
DeleteServerTlsPolicy(std::string const &, Options)
Deletes a single ServerTlsPolicy.
Parameters | |
---|---|
Name | Description |
name |
std::string const &
Required. A name of the ServerTlsPolicy to delete. Must be in the format |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
future< StatusOr< google::cloud::networksecurity::v1::OperationMetadata > > |
A |
DeleteServerTlsPolicy(google::cloud::networksecurity::v1::DeleteServerTlsPolicyRequest const &, Options)
Deletes a single ServerTlsPolicy.
Parameters | |
---|---|
Name | Description |
request |
google::cloud::networksecurity::v1::DeleteServerTlsPolicyRequest const &
Unary RPCs, such as the one wrapped by this function, receive a single |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
future< StatusOr< google::cloud::networksecurity::v1::OperationMetadata > > |
A |
ListClientTlsPolicies(std::string const &, Options)
Lists ClientTlsPolicies in a given project and location.
Parameters | |
---|---|
Name | Description |
parent |
std::string const &
Required. The project and location from which the ClientTlsPolicies should be listed, specified in the format |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
StreamRange< google::cloud::networksecurity::v1::ClientTlsPolicy > |
a StreamRange to iterate of the results. See the documentation of this type for details. In brief, this class has |
ListClientTlsPolicies(google::cloud::networksecurity::v1::ListClientTlsPoliciesRequest, Options)
Lists ClientTlsPolicies in a given project and location.
Parameters | |
---|---|
Name | Description |
request |
google::cloud::networksecurity::v1::ListClientTlsPoliciesRequest
Unary RPCs, such as the one wrapped by this function, receive a single |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
StreamRange< google::cloud::networksecurity::v1::ClientTlsPolicy > |
a StreamRange to iterate of the results. See the documentation of this type for details. In brief, this class has |
GetClientTlsPolicy(std::string const &, Options)
Gets details of a single ClientTlsPolicy.
Parameters | |
---|---|
Name | Description |
name |
std::string const &
Required. A name of the ClientTlsPolicy to get. Must be in the format |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
StatusOr< google::cloud::networksecurity::v1::ClientTlsPolicy > |
the result of the RPC. The response message type (google.cloud.networksecurity.v1.ClientTlsPolicy) is mapped to a C++ class using the Protobuf mapping rules. If the request fails, the |
GetClientTlsPolicy(google::cloud::networksecurity::v1::GetClientTlsPolicyRequest const &, Options)
Gets details of a single ClientTlsPolicy.
Parameters | |
---|---|
Name | Description |
request |
google::cloud::networksecurity::v1::GetClientTlsPolicyRequest const &
Unary RPCs, such as the one wrapped by this function, receive a single |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
StatusOr< google::cloud::networksecurity::v1::ClientTlsPolicy > |
the result of the RPC. The response message type (google.cloud.networksecurity.v1.ClientTlsPolicy) is mapped to a C++ class using the Protobuf mapping rules. If the request fails, the |
CreateClientTlsPolicy(std::string const &, google::cloud::networksecurity::v1::ClientTlsPolicy const &, std::string const &, Options)
Creates a new ClientTlsPolicy in a given project and location.
Parameters | |
---|---|
Name | Description |
parent |
std::string const &
Required. The parent resource of the ClientTlsPolicy. Must be in the format |
client_tls_policy |
google::cloud::networksecurity::v1::ClientTlsPolicy const &
Required. ClientTlsPolicy resource to be created. |
client_tls_policy_id |
std::string const &
Required. Short name of the ClientTlsPolicy resource to be created. This value should be 1-63 characters long, containing only letters, numbers, hyphens, and underscores, and should not start with a number. E.g. "client_mtls_policy". |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
future< StatusOr< google::cloud::networksecurity::v1::ClientTlsPolicy > > |
A |
CreateClientTlsPolicy(google::cloud::networksecurity::v1::CreateClientTlsPolicyRequest const &, Options)
Creates a new ClientTlsPolicy in a given project and location.
Parameters | |
---|---|
Name | Description |
request |
google::cloud::networksecurity::v1::CreateClientTlsPolicyRequest const &
Unary RPCs, such as the one wrapped by this function, receive a single |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
future< StatusOr< google::cloud::networksecurity::v1::ClientTlsPolicy > > |
A |
UpdateClientTlsPolicy(google::cloud::networksecurity::v1::ClientTlsPolicy const &, google::protobuf::FieldMask const &, Options)
Updates the parameters of a single ClientTlsPolicy.
Parameters | |
---|---|
Name | Description |
client_tls_policy |
google::cloud::networksecurity::v1::ClientTlsPolicy const &
Required. Updated ClientTlsPolicy resource. |
update_mask |
google::protobuf::FieldMask const &
Optional. Field mask is used to specify the fields to be overwritten in the ClientTlsPolicy resource by the update. The fields specified in the update_mask are relative to the resource, not the full request. A field will be overwritten if it is in the mask. If the user does not provide a mask then all fields will be overwritten. |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
future< StatusOr< google::cloud::networksecurity::v1::ClientTlsPolicy > > |
A |
UpdateClientTlsPolicy(google::cloud::networksecurity::v1::UpdateClientTlsPolicyRequest const &, Options)
Updates the parameters of a single ClientTlsPolicy.
Parameters | |
---|---|
Name | Description |
request |
google::cloud::networksecurity::v1::UpdateClientTlsPolicyRequest const &
Unary RPCs, such as the one wrapped by this function, receive a single |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
future< StatusOr< google::cloud::networksecurity::v1::ClientTlsPolicy > > |
A |
DeleteClientTlsPolicy(std::string const &, Options)
Deletes a single ClientTlsPolicy.
Parameters | |
---|---|
Name | Description |
name |
std::string const &
Required. A name of the ClientTlsPolicy to delete. Must be in the format |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
future< StatusOr< google::cloud::networksecurity::v1::OperationMetadata > > |
A |
DeleteClientTlsPolicy(google::cloud::networksecurity::v1::DeleteClientTlsPolicyRequest const &, Options)
Deletes a single ClientTlsPolicy.
Parameters | |
---|---|
Name | Description |
request |
google::cloud::networksecurity::v1::DeleteClientTlsPolicyRequest const &
Unary RPCs, such as the one wrapped by this function, receive a single |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
future< StatusOr< google::cloud::networksecurity::v1::OperationMetadata > > |
A |