Esempio n. 1
0
        public virtual Response <Key> CreateRsaKey(RsaKeyCreateOptions rsaKey, CancellationToken cancellationToken = default)
        {
            if (rsaKey == default)
            {
                throw new ArgumentNullException(nameof(rsaKey));
            }

            var parameters = new KeyRequestParameters(rsaKey);

            return(SendRequest(HttpPipelineMethod.Put, parameters, () => new Key(rsaKey.Name), cancellationToken, KeysPath, rsaKey.Name, "create"));
        }
Esempio n. 2
0
        /// <summary>
        /// Creates and stores a new RSA key in Key Vault.
        /// </summary>
        /// <remarks>
        /// If the named key already exists, Azure Key Vault creates a new
        /// version of the key. It requires the keys/create permission.
        /// </remarks>
        /// <param name="rsaKey">The key options object containing information about the RSA key being created.</param>
        /// <param name="cancellationToken">A <see cref="CancellationToken"/> controlling the request lifetime.</param>
        public virtual async Task <Response <Key> > CreateRsaKeyAsync(RsaKeyCreateOptions rsaKey, CancellationToken cancellationToken = default)
        {
            if (rsaKey == default)
            {
                throw new ArgumentNullException(nameof(rsaKey));
            }

            var parameters = new KeyRequestParameters(rsaKey);

            return(await SendRequestAsync(RequestMethod.Post, parameters, () => new Key(rsaKey.Name), cancellationToken, KeysPath, rsaKey.Name, "/create").ConfigureAwait(false));
        }
Esempio n. 3
0
        public virtual async Task <Response <Key> > CreateRsaKeyAsync(RsaKeyCreateOptions rsaKey, CancellationToken cancellationToken = default)
        {
            await Task.CompletedTask;

            throw new NotImplementedException();
        }
Esempio n. 4
0
 public virtual Response <Key> CreateRsaKey(RsaKeyCreateOptions rsaKey, CancellationToken cancellationToken = default)
 {
     throw new NotImplementedException();
 }