Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error: Hostname/IP doesn't match certificate's altnames - when trying to run the examples #266

Closed
ragulka opened this issue Jan 15, 2014 · 5 comments

Comments

@ragulka
Copy link

ragulka commented Jan 15, 2014

I am getting the following error after a fresh install of 00_simple example from rendr/examples. All I did was cd 00_simple && npm install && grunt server.
This seems to happen with other examples as well. Am I doing something wrong?

Error: Hostname/IP doesn't match certificate's altnames
    at SecurePair.<anonymous> (tls.js:1379:23)
    at SecurePair.EventEmitter.emit (events.js:92:17)
    at SecurePair.maybeInitFinished (tls.js:982:10)
    at CleartextStream.read [as _read] (tls.js:469:13)
    at CleartextStream.Readable.read (_stream_readable.js:320:10)
    at EncryptedStream.write [as _write] (tls.js:366:25)
    at doWrite (_stream_writable.js:221:10)
    at writeOrBuffer (_stream_writable.js:211:5)
    at EncryptedStream.Writable.write (_stream_writable.js:180:11)
    at write (_stream_readable.js:583:24)

I have not experienced anything like that with any other node apps.

@rcs
Copy link
Contributor

rcs commented Jan 19, 2014

IIRC, this problem was fixed with 318bfe2, which is after the 0.5.0-rc1 tag, but there's no more recent version to use in package.json. The short answer is that the Host header is being passed through to the remote request, and since it's not the remote hostname, node throws an SSL error.

You can play with the examples by running "npm link ../../../rendr" in the 00_simple directory, which will link your checked out rendr repo into node_modules, or by changing package.json to point to the github repo instead.

@iDVB
Copy link

iDVB commented Jan 22, 2014

Hey thanks rcs,
Can you offer any direction on how to go about making the package.json update?

"rendr": "https://github.com/airbnb/rendr.git#24e11497c057fada3a359abaec6b704decd31284",

I've used the above to try and point to the latest (at the time) commit based off what I read in the NPM docs https://npmjs.org/doc/json.html#Git-URLs-as-Dependencies

Any ideas?

@iDVB
Copy link

iDVB commented Jan 22, 2014

NM, I guess I'm a newb. npm/npm#3638
I did not know that I had to use verbatim git+https: in the url. I thought it was just saying.. either / or.
Also, I had to delete node_modules directory and npm install again.

Works now. Thanks!

@sahat
Copy link

sahat commented Jan 24, 2014

Here is a quick fix for now:

Open package.json and change:

"rendr": "0.5.0-rc1"

to

"rendr": "git+https://github.com/airbnb/rendr.git#318bfe2"

@c089
Copy link
Member

c089 commented Feb 6, 2014

Closing this one as it's a duplicate of #237.

@c089 c089 closed this as completed Feb 6, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants