Amazon.CloudFront.AmazonCloudFrontUrlSigner.SignUrlCanned C# (CSharp) Метод

SignUrlCanned() публичный статический Метод

Generate a signed URL that allows access to a specific distribution and resource path by applying a access restrictions from a "canned" (simplified) policy document.
public static SignUrlCanned ( string resourceUrlOrPath, string keyPairId, FileInfo privateKey, System.DateTime expiresOn ) : String
resourceUrlOrPath string /// The URL or path that uniquely identifies a resource within a /// distribution. For standard distributions the resource URL will /// be "http://" + distributionName + "/" + path /// (may also include URL parameters. For distributions with the /// HTTPS required protocol, the resource URL must start with /// "https://". RTMP resources do not take the form of a /// URL, and instead the resource path is nothing but the stream's /// name. ///
keyPairId string Identifier of a public/private certificate keypair already configured in your Amazon Web Services account.
privateKey System.IO.FileInfo The RSA private key data that corresponding to the certificate keypair identified by keyPairId.
expiresOn System.DateTime The time and date when the signed URL will expire.
Результат String
        public static String SignUrlCanned(string resourceUrlOrPath,
                                           string keyPairId,
                                           FileInfo privateKey,
                                           DateTime expiresOn)
        {
            using (StreamReader reader = new StreamReader(File.OpenRead(privateKey.FullName)))
            {
                return SignUrlCanned(resourceUrlOrPath, keyPairId, reader, expiresOn);
            }
        }

Same methods

AmazonCloudFrontUrlSigner::SignUrlCanned ( string resourceUrlOrPath, string keyPairId, TextReader privateKey, System.DateTime expiresOn ) : String