コード例 #1
0
ファイル: CookieBasedSessions.cs プロジェクト: ToJans/Nancy
 /// <summary>
 /// Initializes a new instance of the <see cref="CookieBasedSessions"/> class.
 /// </summary>
 /// <param name="encryptionProvider">The encryption provider.</param>
 /// <param name="passPhrase">The encryption pass phrase.</param>
 /// <param name="salt">The encryption salt.</param>
 /// <param name="sessionObjectFormatter">Session object formatter to use</param>
 public CookieBasedSessions(IEncryptionProvider encryptionProvider, string passPhrase, string salt, ISessionObjectFormatter sessionObjectFormatter)
 {
     this.encryptionProvider = encryptionProvider;
     this.passPhrase = passPhrase;
     this.salt = CreateSalt(salt);
     this.formatter = sessionObjectFormatter;
 }
コード例 #2
0
ファイル: CookieBasedSessions.cs プロジェクト: marto83/Appia
 /// <summary>
 /// Initializes a new instance of the <see cref="CookieBasedSessions"/> class.
 /// </summary>
 /// <param name="encryptionProvider">The encryption provider.</param>
 /// <param name="hmacProvider">The hmac provider</param>
 /// <param name="passPhrase">The encryption pass phrase.</param>
 /// <param name="salt">The encryption salt.</param>
 /// <param name="hmacPassphrase">The hmac passphrase</param>
 /// <param name="sessionObjectFormatter">Session object formatter to use</param>
 public CookieBasedSessions(IEncryptionProvider encryptionProvider, IHmacProvider hmacProvider, string passPhrase, string salt, string hmacPassphrase, ISessionObjectFormatter sessionObjectFormatter)
 {
     this.encryptionProvider = encryptionProvider;
     this.hmacProvider       = hmacProvider;
     this.passPhrase         = passPhrase;
     this.salt           = CreateSalt(salt);
     this.hmacPassphrase = hmacPassphrase;
     this.formatter      = sessionObjectFormatter;
 }
コード例 #3
0
ファイル: CookieBasedSessions.cs プロジェクト: nuxleus/Nancy
 /// <summary>
 /// Using the specified formatter
 /// </summary>
 /// <param name="newFormatter">Formatter to use</param>
 public void WithFormatter(ISessionObjectFormatter newFormatter)
 {
     this.formatter = newFormatter;
 }
コード例 #4
0
 /// <summary>
 /// Initializes a new instance of the <see cref="CookieBasedSessions"/> class.
 /// </summary>
 /// <param name="encryptionProvider">The encryption provider.</param>
 /// <param name="hmacProvider">The hmac provider</param>
 /// <param name="sessionObjectFormatter">Session object formatter to use</param>
 public CookieBasedSessions(IEncryptionProvider encryptionProvider, IHmacProvider hmacProvider, ISessionObjectFormatter sessionObjectFormatter)
 {
     this.encryptionProvider = encryptionProvider;
     this.hmacProvider = hmacProvider;
     this.formatter = sessionObjectFormatter;
 }
コード例 #5
0
ファイル: CookieBasedSessions.cs プロジェクト: marto83/Appia
 /// <summary>
 /// Using the specified formatter
 /// </summary>
 /// <param name="newFormatter">Formatter to use</param>
 public void WithFormatter(ISessionObjectFormatter newFormatter)
 {
     this.formatter = newFormatter;
 }