+4
−0
+2
−0
+14
−47
Loading
This is a preparation to support per portal group CHAP authentication for discovery session. Previously require_chap, disable_chap, and mutual_chap had been set and used in iscsi_negotiate_param(), and chap_group had been set and used in iscsi_get_authinfo(). If a connection is in a discovery session, the connection can get all CHAP params at its creation, spdk_iscsi_conn_construct(). If a connection is in a normal session, the connection can get all CHAP params in iscsi_op_login_negotiate_chap_param(). Each connection is in either discovery session or normal session. So the following change is possible and is done in this patch. spdk_iscsi_conn_construct() sets all CHAP params of the connection by global parameters. Then iscsi_op_login_negotiate_chap_param() overwrites them by the corresponding target's parameters. iscsi_negotiate_chap_param() and iscsi_get_authinfo() just refer the CHAP params. Besides, iscsi_get_authinfo() changed to call just spdk_iscsi_chap_get_authinfo() inside, and so inline spdk_iscsi_chap_get_authinfo() into iscsi_auth_params() and then remove iscsi_get_authinfo(). Signed-off-by:Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> Change-Id: I8028673cc6923e1b8bc20af55e0c3cc933972fc0 Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/469218 Tested-by:
SPDK CI Jenkins <sys_sgci@intel.com> Reviewed-by:
Jim Harris <james.r.harris@intel.com> Reviewed-by:
Ben Walker <benjamin.walker@intel.com>