예제 #1
0
 /// <summary>
 /// Handles the ReceivedToken event of the infoCardSelector control.
 /// </summary>
 /// <param name="sender">The source of the event.</param>
 /// <param name="e">The <see cref="DotNetOpenAuth.InfoCard.ReceivedTokenEventArgs"/> instance containing the event data.</param>
 private void InfoCardSelector_ReceivedToken(object sender, ReceivedTokenEventArgs e)
 {
     this.Page.Response.SetCookie(new HttpCookie("openid_identifier", "infocard")
     {
         Path = this.Page.Request.ApplicationPath,
     });
     this.OnReceivedToken(e);
 }
예제 #2
0
        /// <summary>
        /// Fires the <see cref="ReceivedToken"/> event.
        /// </summary>
        /// <param name="e">The token, if it was decrypted.</param>
        protected virtual void OnReceivedToken(ReceivedTokenEventArgs e)
        {
            Requires.NotNull(e, "paramName");

            var receivedInfoCard = this.ReceivedToken;

            if (receivedInfoCard != null)
            {
                receivedInfoCard(this, e);
            }
        }
예제 #3
0
        /// <summary>
        /// Fires the <see cref="ReceivedToken"/> event.
        /// </summary>
        /// <param name="e">The token, if it was decrypted.</param>
        protected virtual void OnReceivedToken(ReceivedTokenEventArgs e)
        {
            Contract.Requires(e != null);
            ErrorUtilities.VerifyArgumentNotNull(e, "e");

            var receivedInfoCard = this.ReceivedToken;

            if (receivedInfoCard != null)
            {
                receivedInfoCard(this, e);
            }
        }
예제 #4
0
 protected void InfoCardSelector1_ReceivedToken(object sender, ReceivedTokenEventArgs e)
 {
     this.AddIdentifier(AuthenticationToken.SynthesizeClaimedIdentifierFromInfoCard(e.Token.UniqueId), e.Token.SiteSpecificId);
 }
예제 #5
0
 protected void openIdSelector_ReceivedToken(object sender, ReceivedTokenEventArgs e)
 {
     this.LoginUser(RelyingPartyLogic.User.ProcessUserLogin(e.Token));
 }