Uploaded image for project: 'RHEL'
  1. RHEL
  2. RHEL-121768

(rfe) backport openssh MaxStartups fix from 10.1

Linking RHIVOS CVEs to...Migration: Automation ...SWIFT: POC ConversionSync from "Extern...XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Normal Normal
    • None
    • rhel-10.0
    • openssh
    • None
    • None
    • None
    • eddd1d2daa64a6ab1a915ca88436fa41aede44d4
    • rhel-security-crypto-diamonds
    • None
    • False
    • False
    • Hide

      None

      Show
      None
    • None
    • None
    • None
    • None
    • Unspecified
    • Unspecified
    • Unspecified
    • x86_64
    • None

      Openssh-10.1 contains fix (https://anongit.mindrot.org/openssh.git/commit/?id=eddd1d2daa64a6ab1a915ca88436fa41aede44d4)

      for MaxStartup/PerSourceMaxStartups handling/accounting.

      Please consider backporting this fix for rhel10.

      (From 10.1 changelog(https://lwn.net/ml/all/dd12623ae86aa5eb@cvs.openbsd.org/)

      these fixes could also be relevant:

      ).

      What were you trying to do that didn't work?

      Set

      MaxStartups 10:30:60
      PerSourceMaxStartups 6

      PerSourcePenalties crash:180 authfail:8 noauth:3 grace-exceeded:20 max:900 min:10
      PerSourcePenaltyExemptList your.ip.address/32

      Then repeatedly login/exit, and pretty soon sshd will refuse connections. (even though there are no active ssh connections) Adding your address to PerSourcePenaltyExemptList doesn't seem to help.

      And afaik I can tell after sshd starts refusing connections you'll need:

      systemctl reload sshd

      or connect from different address (if possible). Otherwise 

      What is the impact of this issue to you?

      I have to set PerSourceMaxStartups artificially high and periodically run

      systemctl reload sshd to stop sshd from blocking access.

      Please provide the package NVR for which the bug is seen:

      openssh-server-9.9p1-7.el10_0.x86_64

      How reproducible is this bug?:

      Seems easily reproducible.

      Steps to reproduce

      1. Set config options from above (MaxStartups/PerSourceMaxStartups/PerSourcePenalties
      2. Repeatedly login/logout from same address and sshd should start refusing connections.
      3.  

      Expected results

      PerSourceMaxStartups 4, should allow at least one connection (if there're no other connection attempts).

      Actual results

              dbelyavs@redhat.com Dmitry Belyavskiy
              tike-rhn@uef.fi Jarno Huuskonen
              Dmitry Belyavskiy Dmitry Belyavskiy
              Miluse Bezo Konecna Miluse Bezo Konecna
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

                Created:
                Updated: