• 
      
    Fish Trophy

    chipx86 got a fish trophy!

    Fish Trophy

    Add Certificate.create_from_server().

    Review Request #14941 — Created March 18, 2026 and submitted

    Information

    Review Board
    release-7.1.x

    Reviewers

    This method constructs a Certificate instance from a server,
    containing the hostname, port, and certificate data. This can be used
    to retrieve state from a certificate when encountering an SSL error,
    which does not itself represent certificate information.

    No validation on the certificate itself will be performed (aside from
    attempting to load the content). It's the caller's responsibility to
    process the certificate in whichever way it needs.

    Unit tests pass.

    Used this in the upcoming SSL error class work.

    Summary ID
    Add Certificate.create_from_server().
    This method constructs a `Certificate` instance from a server, containing the hostname, port, and certificate data. This can be used to retrieve state from a certificate when encountering an SSL error, which does not itself represent certificate information. No validation on the certificate itself will be performed (aside from attempting to load the content). It's the caller's responsibility to process the certificate in whichever way it needs.
    8b7b085dcb5af3192b59d0fd6cb5bf715186a513
    Description From Last Updated

    While this is caught just below, perhaps ValueError is more appropriate.

    david david

    This doesn't fix the problem with it being macos-specific ([Errno 8] nodename nor servname provided, or not known). On Linux …

    david david

    This exact error message is macos specific.

    david david
    david
    1. 
        
    2. reviewboard/certs/cert.py (Diff revision 1)
       
       
      Show all issues

      While this is caught just below, perhaps ValueError is more appropriate.

    3. reviewboard/certs/tests/test_certificate.py (Diff revision 1)
       
       
       
       
      Show all issues

      This exact error message is macos specific.

    4. 
        
    chipx86
    maubin
    1. Ship It!
    2. 
        
    david
    1. 
        
    2. reviewboard/certs/tests/test_certificate.py (Diff revisions 1 - 2)
       
       
       
       
       
       
       
       
      Show all issues

      This doesn't fix the problem with it being macos-specific ([Errno 8] nodename nor servname provided, or not known). On Linux the error looks more like [Errno -2] Name or service not known.

      1. I just completely screwed that up.

    3. 
        
    chipx86
    david
    1. Ship It!
    2. 
        
    chipx86
    Review request changed
    Status:
    Completed
    Change Summary:
    Pushed to release-8.x (9d56033)