[GH-ISSUE #52] Cannot upload certificate files #49

Closed
opened 2026-02-26 05:33:53 +03:00 by kerem · 3 comments
Owner

Originally created by @Grekkor on GitHub (Jan 13, 2019).
Original GitHub issue: https://github.com/NginxProxyManager/nginx-proxy-manager/issues/52

I cannot upload certificate files,
It just does nothing and then says: "Upload failed: 0"

Originally created by @Grekkor on GitHub (Jan 13, 2019). Original GitHub issue: https://github.com/NginxProxyManager/nginx-proxy-manager/issues/52 I cannot upload certificate files, It just does nothing and then says: "Upload failed: 0"
kerem 2026-02-26 05:33:53 +03:00
  • closed this issue
  • added the
    bug
    label
Author
Owner

@jc21 commented on GitHub (Jan 14, 2019):

Anything in the docker logs?

<!-- gh-comment-id:453903685 --> @jc21 commented on GitHub (Jan 14, 2019): Anything in the docker logs?
Author
Owner

@Grekkor commented on GitHub (Jan 14, 2019):

Only:

Connection Error: Error: Connection lost: The server closed the connection.

I generated the certificate files on linux. I got two .pem files.
I tried uploading them as .crt and .key files aswell but no luck.
Here the command I used:
openssl req -x509 -newkey rsa:4096 -keyout HomeCertificateKey.pem -out HomeCertificateCert.pem -days 365

Edit: Nvm, the docker log entry has nothing to do with this issue in my opinion. I just tested it again and nothing new appears in the log.
Edit 2: When trying to upload .txt files then I get:

Upload failed: 400

and a log entry:
[1/14/2019] [6:53:05 AM] [Express ] › ⚠ warning Certificate is not valid (Command failed: openssl x509 -in /tmp/6cba1486-d794-45ef-8e21-397f1df69b6d/tmp -subject -noout unable to load certificate 140095325644032:error:0906D06C:PEM routines:PEM_read_bio:no start line:../crypto/pem/pem_lib.c:691:Expecting: TRUSTED CERTIFICATE)
Hence my assumption is it has to do with certificate validation, which is maybe stuck in an infinite loop? It takes like a good 1-2 minutes before the error notification appears. The 400 error appears instantaneously.

Edit 3: The upload succeeds when using the -nodes option to disable DES. I now used the following command:
openssl req -newkey rsa:4096 -nodes -keyout HomeCertificateKey.pem -x509 -days 365 -out HomeCertificateCert.pem
I suggest you either support DES or document somewhere the constraints on the certificates.

<!-- gh-comment-id:453912974 --> @Grekkor commented on GitHub (Jan 14, 2019): Only: > Connection Error: Error: Connection lost: The server closed the connection. I generated the certificate files on linux. I got two .pem files. I tried uploading them as .crt and .key files aswell but no luck. Here the command I used: `openssl req -x509 -newkey rsa:4096 -keyout HomeCertificateKey.pem -out HomeCertificateCert.pem -days 365` **Edit**: Nvm, the docker log entry has nothing to do with this issue in my opinion. I just tested it again and nothing new appears in the log. **Edit 2**: When trying to upload .txt files then I get: > Upload failed: 400 and a log entry: ` [1/14/2019] [6:53:05 AM] [Express ] › ⚠ warning Certificate is not valid (Command failed: openssl x509 -in /tmp/6cba1486-d794-45ef-8e21-397f1df69b6d/tmp -subject -noout unable to load certificate 140095325644032:error:0906D06C:PEM routines:PEM_read_bio:no start line:../crypto/pem/pem_lib.c:691:Expecting: TRUSTED CERTIFICATE)` Hence my assumption is it has to do with certificate validation, which is maybe stuck in an infinite loop? It takes like a good 1-2 minutes before the error notification appears. The 400 error appears instantaneously. **Edit 3**: The upload succeeds when using the -nodes option to disable DES. I now used the following command: `openssl req -newkey rsa:4096 -nodes -keyout HomeCertificateKey.pem -x509 -days 365 -out HomeCertificateCert.pem ` I suggest you either support DES or document somewhere the constraints on the certificates.
Author
Owner

@chaptergy commented on GitHub (May 10, 2021):

This issue should be fixed, certificate upload is currently working.

<!-- gh-comment-id:837227458 --> @chaptergy commented on GitHub (May 10, 2021): This issue should be fixed, certificate upload is currently working.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/nginx-proxy-manager-NginxProxyManager#49
No description provided.