1
0
mirror of https://github.com/v2fly/v2ray-core.git synced 2026-04-11 08:15:27 -04:00

h2 transport

This commit is contained in:
Darien Raymond
2018-03-01 13:16:52 +01:00
parent af29e42771
commit d207d953bd
14 changed files with 467 additions and 28 deletions

View File

@@ -29,12 +29,12 @@ func GenerateCertificateForTest() *v2tls.Certificate {
Subject: pkix.Name{
Organization: []string{"V2Ray Inc"},
},
NotBefore: time.Now(),
NotBefore: time.Now().Add(time.Hour * -1),
NotAfter: time.Now().Add(time.Hour),
KeyUsage: x509.KeyUsageKeyEncipherment | x509.KeyUsageDigitalSignature,
ExtKeyUsage: []x509.ExtKeyUsage{x509.ExtKeyUsageServerAuth},
BasicConstraintsValid: true,
DNSNames: []string{"www.v2ray.com"},
DNSNames: []string{"www.v2ray.com", "v2ray.com"},
}
derBytes, err := x509.CreateCertificate(rand.Reader, &template, &template, &priv.PublicKey, priv)