| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
|
| 7 |
|
| 8 |
package main |
| 9 |
|
| 10 |
import "c2sp.org/CCTV/age/internal/testkit" |
| 11 |
|
| 12 |
func main() { |
| 13 |
f := testkit.NewTestFile() |
| 14 |
f.VersionLine("v1") |
| 15 |
f.HybridRecordIdentity(testkit.TestHybridIdentity) |
| 16 |
share := make([]byte, 32) |
| 17 |
f.HybridStanza(share, f.Rand(32), testkit.TestHybridIdentity) |
| 18 |
f.HMAC() |
| 19 |
f.Payload("age") |
| 20 |
f.ExpectHeaderFailure() |
| 21 |
f.Comment("the X25519 part of enc is the identity point, so the shared secret" + |
| 22 |
"is the disallowed all-zero value") |
| 23 |
f.Generate() |
| 24 |
} |