Fuzz is the go-fuzz fuzzing function
(data []byte)
| 34 | |
| 35 | // Fuzz is the go-fuzz fuzzing function |
| 36 | func Fuzz(data []byte) int { |
| 37 | doc := etree.NewDocument() |
| 38 | if err := doc.ReadFromBytes(data); err != nil { |
| 39 | return 0 |
| 40 | } |
| 41 | if doc.Root() == nil { |
| 42 | return 0 |
| 43 | } |
| 44 | |
| 45 | if _, err := Decrypt(testKey, doc.Root()); err != nil { |
| 46 | return 0 |
| 47 | } |
| 48 | return 1 |
| 49 | } |