summaryrefslogtreecommitdiff
path: root/usr/auth.h
diff options
context:
space:
mode:
authorChris Leech <cleech@redhat.com>2019-06-13 16:07:07 -0700
committerChris Leech <cleech@redhat.com>2019-10-07 15:05:46 -0700
commit155cc45b25f29c08041c4d04646ed53c9e33f0f3 (patch)
tree3ad3aaab65fe8270ab25151575820282d60c40f6 /usr/auth.h
parent288add22d6b61cc68ede358faeec9affb15019cd (diff)
downloadopen-iscsi-155cc45b25f29c08041c4d04646ed53c9e33f0f3.tar.gz
CHAP SHA1, SHA3-256 via OpenSSL's libcrypto
Extended CHAP authentication modes using newer hash digest functions than MD5. Makes OpenSSL libcrypto use a requirement, replacing the in tree MD5 implementation as well (and removing the unused SHA1 code).
Diffstat (limited to 'usr/auth.h')
-rw-r--r--usr/auth.h9
1 files changed, 7 insertions, 2 deletions
diff --git a/usr/auth.h b/usr/auth.h
index 2cc3489..d36163c 100644
--- a/usr/auth.h
+++ b/usr/auth.h
@@ -29,7 +29,10 @@ enum {
AUTH_LARGE_BINARY_MAX_LEN = 1024,
AUTH_RECV_END_MAX_COUNT = 10,
ACL_SIGNATURE = 0x5984B2E3,
- AUTH_CHAP_RSP_LEN = 16,
+ AUTH_CHAP_MD5_RSP_LEN = 16,
+ AUTH_CHAP_SHA1_RSP_LEN = 20,
+ AUTH_CHAP_SHA3_256_RSP_LEN = 32,
+ AUTH_CHAP_RSP_MAX = 32,
};
/*
@@ -61,7 +64,9 @@ enum {
AUTH_METHOD_MAX_COUNT = 2,
AUTH_CHAP_ALG_MD5 = 5,
- AUTH_CHAP_ALG_MAX_COUNT = 2
+ AUTH_CHAP_ALG_SHA1 = 6,
+ AUTH_CHAP_ALG_SHA3_256 = 7,
+ AUTH_CHAP_ALG_MAX_COUNT = 4
};
enum auth_neg_role {