Exemplo n.º 1
0
        private void EnsureAuthSubCredentials(HttpWebRequest request)
        {
            string header = AuthSubUtil.formAuthorizationHeader(
                this.Token,
                this.PrivateKey,
                request.RequestUri,
                request.Method);

            request.Headers.Add(header);
        }
Exemplo n.º 2
0
        /// <summary>
        /// sets up the correct credentials for this call, pending
        /// security scheme
        /// </summary>
        protected override void EnsureCredentials()
        {
            HttpWebRequest http = this.Request as HttpWebRequest;

            string header = AuthSubUtil.formAuthorizationHeader(this.factory.Token,
                                                                this.factory.PrivateKey,
                                                                http.RequestUri,
                                                                http.Method);

            this.Request.Headers.Add(header);
        }