lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:   Mon, 15 Aug 2022 00:56:10 +0800
From:   wenchao hao <haowenchao22@...il.com>
To:     Mike Christie <michael.christie@...cle.com>
Cc:     Wenchao Hao <haowenchao@...wei.com>, Lee Duncan <lduncan@...e.com>,
        Chris Leech <cleech@...hat.com>,
        "James E . J . Bottomley" <jejb@...ux.ibm.com>,
        "Martin K . Petersen" <martin.petersen@...cle.com>,
        open-iscsi@...glegroups.com, linux-scsi@...r.kernel.org,
        linux-kernel@...r.kernel.org, linfeilong@...wei.com
Subject: Re: [PATCH v3] scsi: iscsi: Fix multiple iscsi session unbind event
 sent to userspace

On Fri, Aug 12, 2022 at 12:06 PM Mike Christie
<michael.christie@...cle.com> wrote:
>
> On 8/1/22 10:47 PM, Wenchao Hao wrote:
> > I found an issue that kernel would send ISCSI_KEVENT_UNBIND_SESSION
> > for multiple times which should be fixed.
> >
> > This patch introduce target_state in iscsi_cls_session to make
> > sure session would send only one ISCSI_KEVENT_UNBIND_SESSION.
> >
> > But this would break issue fixed in commit 13e60d3ba287 ("scsi: iscsi:
> > Report unbind session event when the target has been removed"). The issue
> > is iscsid died for any reason after it send unbind session to kernel, once
> > iscsid restart again, it loss kernel's ISCSI_KEVENT_UNBIND_SESSION event.
> >
> > Now kernel think iscsi_cls_session has already sent an
> > ISCSI_KEVENT_UNBIND_SESSION event and would not send it any more. Which
> > would cause userspace unable to logout. Actually the session is in
> > invalid state(it's target_id is INVALID), iscsid should not sync this
> > session in it's restart.
> >
> > So we need to check session's target state during iscsid restart,
> > if session is in unbound state, do not sync this session and perform
> > session teardown. It's reasonable because once a session is unbound, we
> > can not recover it any more(mainly because it's target id is INVALID)
> >
>
> I think we are ok now. Do you have a link to the userspace parts so
> I can make sure we have everything covered now?

I updated the PR on github: https://github.com/open-iscsi/open-iscsi/pull/339

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ