This topic describes how to configure an HTTPS request in Alibaba Cloud Classic SDK for .NET V1.0.
Each API operation has a unique request object. The request object is named in the ${API}${Request} format. For example, a request object can be DescribeRegionRequest.
Alibaba Cloud Classic SDK for .NET allows you to configure a request object to send an API request over HTTPS.
request.Protocol(ProtocolType.HTTPS);By default, if you send an API request over HTTPS, the SDK enables certificate verification to verify the validity of SSL/TLS certificates. If no SSL/TLS certificate is configured in the development environment, an error that indicates the certificate verification fails is reported.
To ensure network communication security, we recommend that you enable certificate verification. If certificate verification must be disabled in the test environment, you can use the following method:
// Disable certificate verification at the client level.
client.SetHttpsInsecure(true);
// Disable certificate verification at the request level.
request.SetHttpsInsecure(true);