mirror of
https://github.com/refraction-networking/uquic.git
synced 2025-04-04 04:37:36 +03:00
introduce a type for the stateless reset key (#3621)
This commit is contained in:
parent
b8447041bb
commit
8d496ebb5e
10 changed files with 35 additions and 27 deletions
|
@ -449,6 +449,7 @@ var _ = Describe("Client", func() {
|
|||
|
||||
Context("quic.Config", func() {
|
||||
It("setups with the right values", func() {
|
||||
srk := &StatelessResetKey{'f', 'o', 'o', 'b', 'a', 'r'}
|
||||
tokenStore := NewLRUTokenStore(10, 4)
|
||||
config := &Config{
|
||||
HandshakeIdleTimeout: 1337 * time.Minute,
|
||||
|
@ -456,7 +457,7 @@ var _ = Describe("Client", func() {
|
|||
MaxIncomingStreams: 1234,
|
||||
MaxIncomingUniStreams: 4321,
|
||||
ConnectionIDLength: 13,
|
||||
StatelessResetKey: []byte("foobar"),
|
||||
StatelessResetKey: srk,
|
||||
TokenStore: tokenStore,
|
||||
EnableDatagrams: true,
|
||||
}
|
||||
|
@ -466,7 +467,7 @@ var _ = Describe("Client", func() {
|
|||
Expect(c.MaxIncomingStreams).To(BeEquivalentTo(1234))
|
||||
Expect(c.MaxIncomingUniStreams).To(BeEquivalentTo(4321))
|
||||
Expect(c.ConnectionIDLength).To(Equal(13))
|
||||
Expect(c.StatelessResetKey).To(Equal([]byte("foobar")))
|
||||
Expect(c.StatelessResetKey).To(Equal(srk))
|
||||
Expect(c.TokenStore).To(Equal(tokenStore))
|
||||
Expect(c.EnableDatagrams).To(BeTrue())
|
||||
})
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue