New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 769771 link

Starred by 4 users

Issue metadata

Status: WontFix
Owner: ----
Closed: Oct 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Windows
Pri: 2
Type: Bug



Sign in to add a comment

ERR_SSL_SERVER_CERT_BAD_FORMAT on WSS connection

Reported by gsikora1...@gmail.com, Sep 28 2017

Issue description

UserAgent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:55.0) Gecko/20100101 Firefox/55.0

Steps to reproduce the problem:
1. 
2. 
3. 

What is the expected behavior?
-

What went wrong?
Hi ! 
I use websockets (ssl) to connect my application with a browser 
there was no problem with google chrome version 60
but since i update to 61 i get error like this 

WebSocket connection to 'wss://localhost:9980/' failed: Error in connection establishment: net::ERR_SSL_SERVER_CERT_BAD_FORMAT

WebSocket connection to 'wss://localhost:9981/' failed: Error in connection establishment: net::ERR_CONNECTION_REFUSED

i tried:
- add more properites like O,OU in subject name 
- add subject alternative name
- change expiry date 
- set shorter serial number 

all that didnt work 

details of certificate
version: V3
serial number:‎00 ca f6 ea 9d
signature algorithm sha256RSA
signatue hash algorithm sha256

Issuer
S = Krakow
L = Malopolska
OU = NOL3Starter
CN = NOL3Starter
O = NOL3Starter
C = PL

‎Valid from 28.09.2017 17:36:30
Valid to ‎1.10.‎2017 17:36:30

Subject
S = Krakow
L = Malopolska
OU = NOL3Starter
CN = NOL3Starter
O = NOL3Starter
C = PL

Public key RSA(2048Bits)
Params for public key 05 00

basic limiting conditions: type of subject: UC, conditions restricting the path length= None
SAN DNS=NOL3Starter
fingerprint algorithm sha1 
fingerprint ‎17 79 78 45 ae f7 af 51 1a 11 4b ed 1e 5e e0 cd 37 a8 47 b2

where is problem ?

Did this work before? N/A 

Chrome version: Wersja 61.0.3163.100  Channel: n/a
OS Version: 10.0
Flash Version: Shockwave Flash 27.0 r0
 
Components: Internals>Network>Certificate
Labels: -Type-Bug-Security -Restrict-View-SecurityTeam Type-Bug
Summary: ERR_SSL_SERVER_CERT_BAD_FORMAT on WSS connection (was: Certificate problem )
Would it be possible for you to attach the .CER file?

This is on Windows 10?

Comment 2 by dandu...@gmail.com, Sep 28 2017

I'm also getting ERR_SSL_SERVER_CERT_BAD_FORMAT when trying to browse using HTTPS on our self-signed devices. 

Used to work on Chrome 60, and works on IE.

I've attached a .p7b file containing the certificate chain. Similarly with the OP, I'm not sure how I can determine what the problem is.
cert_chain.p7b
1.6 KB Download
Re #2: On what OS platform are you encountering this problem?

Comment 4 by mattm@chromium.org, Sep 28 2017

re: comment #2: The validity times in the certificates are encoded incorrectly. They do not include the seconds field, which is required by RFC 5280. (https://tools.ietf.org/html/rfc5280#section-4.1.2.5.1)

    SEQUENCE {
      UTCTime { "0001010000Z" }
      UTCTime { "3001010000Z" }
    }

Comment 5 by dandu...@gmail.com, Sep 28 2017

Thank you for the responses.

OS is Windows 7 SP1 64-bit
Chrome is version 61.0.3163.100 (64-bit)

The certs were generated using openssl 1.0.2k. I can check whether I can add the seconds field easily and confirm if this corrects the issue.

Comment 6 by dandu...@gmail.com, Sep 28 2017

re: Comment 4. I can confirm that adding the seconds field corrects the issue. 

I guess our certs have been wrong for many years -- but still worked on all of our tested browsers. I'm not sure if this is the same issue as the OP. I guess we'll find out if the certificate is posted.

Thanks again.
system: Windows 10 Pro , ver. 10.0.13493 kompilation 14393

cer file (nol3starter.cer) is in attachment

Thanks !



nol3starter.cer
915 bytes Download

Comment 8 by mattm@chromium.org, Sep 29 2017

re #7: I don't get any errors on that cert. Can you capture a netlog demonstrating the error? That should allow us to see if it's actually that cert which is causing the problem. (https://sites.google.com/a/chromium.org/dev/for-testers/providing-network-details)
chrome-net-export-log.json file in attachment
chrome-net-export-log.json
5.1 MB View Download
Do we object to a CA certificate that doesn't have a critical basicConstraints?

cablint	ERROR	basicConstraints must be critical in CA certificates
cablint	ERROR	CA certificates must include keyUsage extension
cablint	ERROR	CA:TRUE without keyCertSign
cablint	WARNING	CA certificates should not include subject alternative names
zlint	ERROR	basicConstraints MUST appear as a critical extension
zlint	ERROR	CAs MUST include a Subject Key Identifier in all CA certificates
zlint	ERROR	Root and Subordinate CA certificate keyUsage extension MUST be present
zlint	ERROR	Root CA certificates MUST have Key Usage Extension Present
zlint	WARNING	Effective September 30, 2016, CAs SHALL generate non‐sequential Certificate serial numbers greater than zero (0) containing at least 64 bits of output from a CSPRNG.
zlint	WARNING	The domain SHOULD NOT have a bare public suffix
re #9: thanks! In that log, the server is sending a different cert chain than the one attached to comment #7. (I attached it here for reference.)  The first cert in the chain is marked as version 1, but has extensions, which are only allowed in version 3 certificates.
769771.wss-localhost.serverchain.pem
13.3 KB Download
thanks a lot ! my mistake, i didnt notice certificate for websocket server, version was wrong and I change it to v.3 , it works great ! 
Cc: hdodda@chromium.org
Status: WontFix (was: Unconfirmed)
@as per comment #12, closing this issue , as it works fine. Please feel free to raise a new issue , if any issues faced in latest chrome channels.

Thanks!
 Issue 797203  has been merged into this issue.

Sign in to add a comment