pass a URL with jimp.read and have option to pass "rejectUnauthorized : false" to the request
See original GitHub issueExpected Behavior
I would like to pass an option rejectUnauthorized : false
to the Jimp.read()` method when I pass a URL to it.
I want to read the image even if there is a problem with the certificate.
I don’t want to configure the behaviour globally to the server.
Current Behavior
If I have somehow troubles to get the certificate of the URL, I get the following error => Error: unable to verify the first certificate
Failure Information (for bugs)
Error unable to verify the first certificate _tls_wrap.js in TLSSocket.<anonymous> at line 1105:38 events.js in emitNone at line 106:13 events.js in TLSSocket.emit at line 208:7 _tls_wrap.js in TLSSocket._finishInit at line 639:8 _tls_wrap.js in TLSWrap.ssl.onhandshakedone at line 469:38
Steps to Reproduce
Jimp.read(‘https://404store.com/2017/12/08/Random-random-30798866-500-325.jpg’)
Context
- Jimp Version: 0.4.0
- Operating System: Unbuntu Server 16.04
- Node version: v8.11.1
Failure Logs
Error unable to verify the first certificate _tls_wrap.js in TLSSocket.<anonymous> at line 1105:38 events.js in emitNone at line 106:13 events.js in TLSSocket.emit at line 208:7 _tls_wrap.js in TLSSocket._finishInit at line 639:8 _tls_wrap.js in TLSWrap.ssl.onhandshakedone at line 469:38
Issue Analytics
- State:
- Created 5 years ago
- Reactions:3
- Comments:12 (5 by maintainers)
Top GitHub Comments
related to #267
@hipstersmoothie, thanks! I am glad to help.
I will make a PR on the weekend.