MCPcopy Index your code
hub / github.com/nodejs/node / getBlockSize

Function getBlockSize

lib/internal/crypto/util.js:906–925  ·  view source on GitHub ↗
(name)

Source from the content-addressed store, hash-verified

904}
905
906function getBlockSize(name) {
907 switch (name) {
908 case 'SHA-1':
909 // Fall through
910 case 'SHA-256':
911 return 512;
912 case 'SHA-384':
913 // Fall through
914 case 'SHA-512':
915 return 1024;
916 case 'SHA3-256':
917 // Fall through
918 case 'SHA3-384':
919 // Fall through
920 case 'SHA3-512':
921 // This interaction is not defined for now.
922 // https://github.com/WICG/webcrypto-modern-algos/issues/23
923 throw lazyDOMException('Explicit algorithm length member is required', 'NotSupportedError');
924 }
925}
926
927function getDigestSizeInBytes(name) {
928 switch (name) {

Callers 2

getKeyLengthFunction · 0.85
hmacGenerateKeyFunction · 0.85

Calls 1

lazyDOMExceptionFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…