[PATCH 2/2] iscsi target: Fix CHAP negotiation setup

2019-04-27 Thread Mike Christie
If the user has disabled authentication and not setup CHAP, we will still try to use CHAP if the initiator sends CHAP,None. The login will then fail because the user didn't setup CHAP. This patch just has us detect when CHAP/authentication has been turned off so we negotiate for None instead of CHA

[PATCH 0/2] iscsi target: fix login negotiation

2019-04-27 Thread Mike Christie
The following patches fix login negotiation when the user has disabled authentication, and the initiator is presenting CHAP,None. The problem is that the target initializes AuthMethod to CHAP (normal session) or CHAP,None (discovery session), but when the user does authentication=0/ enforce_discove

[PATCH 1/2] iscsi target: make function to get auth from conn

2019-04-27 Thread Mike Christie
Move the code to go from iscsi conn to iscsi node auth to a helper function which will also be used in the next patch. Signed-off-by: Mike Christie --- drivers/target/iscsi/iscsi_target_nego.c | 35 +--- 1 file changed, 23 insertions(+), 12 deletions(-) diff --git a/