2ping crashes on non-encrypted session

Bug #1786397 reported by Ryan Finnie
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
2ping (Ubuntu)
Fix Released
High
Ryan Finnie
Bionic
Fix Released
Undecided
Unassigned

Bug Description

[Impact]

 * When 2ping is being run as a non-encrypted session between two affected 4.1 releases, within a few minutes the client and/or server will crash with "TypeError: 'NoneType' object is not subscriptable" in scheduled_cleanup_sock_class.

 * Clients cannot sustain a 2ping session for more than a few minutes.

 * When configured as a daemon without respawn, this results in a denial of service. (Not default in bionic.)

 * SRU fix adds a type check for the encrypted_sessions peer table, which is not initialized if no encrypted packets have been received.

 * Fixed in commit 4a636763850bcea590fba6066751d13a36c2b28d (https://github.com/rfinnie/2ping/commit/4a636763850bcea590fba6066751d13a36c2b28d) and included in upstream version 4.1.2.

[Test Case]

 * In one windows, run `2ping --listen`

 * In another, run `2ping 127.0.0.1`

 * Wait up to 5 minutes for TypeError.

[Regression Potential]

 * SRU might not fix issue.

 * SRU fix might break scheduled cleanup of sessions when encryption *is* activated, leading to resource exhaustion.

 * SRU fix might break scheduled cleanup of other data unrelated to encryption.

 * Patch author has tested these scenarios and cannot reproduce any of them.

[Other Info]

 * Originally reported by Github user joe1981alAPR (https://github.com/rfinnie/2ping/issues/5).

Ryan Finnie (fo0bar)
tags: added: bionic
Changed in 2ping (Ubuntu):
assignee: nobody → Ryan Finnie (fo0bar)
importance: Undecided → High
Revision history for this message
Ryan Finnie (fo0bar) wrote :
description: updated
Revision history for this message
Ryan Finnie (fo0bar) wrote :

[ubuntu/bionic-proposed] 2ping 4.1-1ubuntu1 (Waiting for approval)

> Redirecting ubuntu bionic to ubuntu bionic-proposed.
> This upload awaits approval by a distro manager

Changed in 2ping (Ubuntu):
status: New → Confirmed
Ryan Finnie (fo0bar)
Changed in 2ping (Ubuntu):
status: Confirmed → In Progress
Revision history for this message
Ubuntu Foundations Team Bug Bot (crichton) wrote :

The attachment "Fix cleanup crash on non-encrypted sessions" seems to be a debdiff. The ubuntu-sponsors team has been subscribed to the bug report so that they can review and hopefully sponsor the debdiff. If the attachment isn't a patch, please remove the "patch" flag from the attachment, remove the "patch" tag, and if you are member of the ~ubuntu-sponsors, unsubscribe the team.

[This is an automated message performed by a Launchpad user owned by ~brian-murray, for any issue please contact him.]

tags: added: patch
Revision history for this message
Ryan Finnie (fo0bar) wrote :

Sponsorship isn't needed; upload is waiting for bionic-proposed

Revision history for this message
Brian Murray (brian-murray) wrote : Please test proposed package

Hello Ryan, or anyone else affected,

Accepted 2ping into bionic-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/2ping/4.1-1ubuntu1 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed.Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested and change the tag from verification-needed-bionic to verification-done-bionic. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-bionic. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance!

Changed in 2ping (Ubuntu Bionic):
status: New → Fix Committed
tags: added: verification-needed verification-needed-bionic
Changed in 2ping (Ubuntu):
status: In Progress → Fix Released
Revision history for this message
Ryan Finnie (fo0bar) wrote :

Tested 4.1-1ubuntu1 from bionic-proposed which fixes the issue correctly. No regressions observed.

tags: added: verification-done-bionic
removed: verification-needed-bionic
Ryan Finnie (fo0bar)
tags: added: verification-done
removed: verification-needed
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package 2ping - 4.1-1ubuntu1

---------------
2ping (4.1-1ubuntu1) bionic; urgency=medium

  * SRU: Fix cleanup crash on non-encrypted sessions (LP: #1786397)

 -- Ryan Finnie <email address hidden> Fri, 10 Aug 2018 04:31:04 +0000

Changed in 2ping (Ubuntu Bionic):
status: Fix Committed → Fix Released
Revision history for this message
Łukasz Zemczak (sil2100) wrote : Update Released

The verification of the Stable Release Update for 2ping has completed successfully and the package has now been released to -updates. Subsequently, the Ubuntu Stable Release Updates Team is being unsubscribed and will not receive messages about this bug report. In the event that you encounter a regression using the package from -updates please report a new bug using ubuntu-bug and tag the bug report regression-update so we can easily find any regressions.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.