aboutsummaryrefslogtreecommitdiffstats
path: root/libparc/parc/security/parc_CryptoSuite.c
diff options
context:
space:
mode:
authorAlberto Compagno <acompagn+fdio@cisco.com>2018-04-16 15:28:53 +0000
committerGerrit Code Review <gerrit@fd.io>2018-04-16 15:28:53 +0000
commit07d0a90b6f52fa920ab3a4a9984b0ba1fbb7f9f8 (patch)
treef3810af54c63c0f1bb5226e84897411c41b40d03 /libparc/parc/security/parc_CryptoSuite.c
parentd609ef19bac231a47b65cf5a6a797c142ebc625d (diff)
parent799484812a3fdd9d5d6e71c5fc4b483043347bca (diff)
Merge "Added method to retrieve the signature length from the signer. Fixed bug on parc-publickey" into cframework/master
Diffstat (limited to 'libparc/parc/security/parc_CryptoSuite.c')
-rwxr-xr-xlibparc/parc/security/parc_CryptoSuite.c24
1 files changed, 0 insertions, 24 deletions
diff --git a/libparc/parc/security/parc_CryptoSuite.c b/libparc/parc/security/parc_CryptoSuite.c
index 7bd0a7bf..43339121 100755
--- a/libparc/parc/security/parc_CryptoSuite.c
+++ b/libparc/parc/security/parc_CryptoSuite.c
@@ -45,30 +45,6 @@ parcCryptoSuite_GetCryptoHash(PARCCryptoSuite suite)
}
int
-parcCryptoSuite_GetSignatureSizeBits(PARCCryptoSuite suite, int keyLengthBits)
-{
- switch (suite) {
- case PARCCryptoSuite_DSA_SHA256: // fallthrough
- case PARCCryptoSuite_RSA_SHA256: // fallthrough
- case PARCCryptoSuite_RSA_SHA512:
- return keyLengthBits;
-
- case PARCCryptoSuite_ECDSA_SHA256:
- return keyLengthBits*2 + 64; //Overhead added by ECDSA
-
- case PARCCryptoSuite_HMAC_SHA256: // fallthrough
- case PARCCryptoSuite_HMAC_SHA512: // fallthrough
- return 512;
-
- case PARCCryptoSuite_NULL_CRC32C:
- return 32;
-
- default:
- trapIllegalValue(suite, "Unknown crypto suite: %d", suite);
- }
-}
-
-int
parcCryptoSuite_GetSignatureSizeBytes(PARCCryptoSuite suite, int keyLengthBits)
{
int keyLengthBytes = keyLengthBits >> 3;