(name, length)
| 57 | }; |
| 58 | |
| 59 | function getAlgorithmName(name, length) { |
| 60 | switch (name) { |
| 61 | case 'AES-CBC': return `A${length}CBC`; |
| 62 | case 'AES-CTR': return `A${length}CTR`; |
| 63 | case 'AES-GCM': return `A${length}GCM`; |
| 64 | case 'AES-KW': return `A${length}KW`; |
| 65 | case 'AES-OCB': return `A${length}OCB`; |
| 66 | } |
| 67 | } |
| 68 | |
| 69 | function validateKeyLength(length) { |
| 70 | if (length !== 128 && length !== 192 && length !== 256) |
no outgoing calls
no test coverage detected
searching dependent graphs…