From 358d8ffad650b6fb966082e7bd1460b0d6a4eacc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tobias=20Nie=C3=9Fen?= Date: Fri, 13 Apr 2018 18:02:46 +0200 Subject: [PATCH] crypto: allow to restrict valid GCM tag length This change allows users to restrict accepted GCM authentication tag lengths to a single value. PR-URL: https://github.com/nodejs/node/pull/20039 Fixes: https://github.com/nodejs/node/issues/17523 Reviewed-By: James M Snell Reviewed-By: Yihong Wang Reviewed-By: Ben Noordhuis --- doc/api/crypto.md | 8 ++++- src/node_crypto.cc | 33 ++++++++++++++++--- src/node_crypto.h | 3 +- test/parallel/test-crypto-authenticated.js | 37 ++++++++++++++++++++++ 4 files changed, 74 insertions(+), 7 deletions(-) diff --git a/doc/api/crypto.md b/doc/api/crypto.md index b4ff52d89d6181..47181f6a2c39fb 100644 --- a/doc/api/crypto.md +++ b/doc/api/crypto.md @@ -1457,6 +1457,10 @@ to create the `Decipher` object.