FS#30620 - [nodejs] 0.8.x openssl error when npm installing modules (arm)

Attached to Project: Community Packages
Opened by Martin Benda (Bendis) - Tuesday, 10 July 2012, 07:11 GMT
Last edited by Bartłomiej Piotrowski (Barthalion) - Sunday, 15 July 2012, 17:49 GMT
Task Type Bug Report
Category Packages
Status Closed
Assigned To Bartłomiej Piotrowski (Barthalion)
Architecture All
Severity Medium
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Hi,

yesterday I installed Raspberry Pi Arch Linux image on my RPi box (arm architecture), updated the system (pacman -Syu) and installed community/nodejs-0.8.1-1. When I try to install any node.js module using npm, I get the following error:

[bendis@bendis-rpi ~]$ npm install underscore
npm http GET https://registry.npmjs.org/underscore
npm http GET https://registry.npmjs.org/underscore
npm http GET https://registry.npmjs.org/underscore
npm ERR! Error: 1075032064:error:1408D108:SSL routines:SSL3_GET_KEY_EXCHANGE:wrong signature length:../deps/openssl/openssl/ssl/s3_clnt.c:1617:
npm ERR!
npm ERR! at CleartextStream._puller (tls.js:519:24)
npm ERR! at CleartextStream.CryptoStream._pull (tls.js:453:19)
npm ERR! at SecurePair.cycle (tls.js:743:20)
npm ERR! at EncryptedStream.CryptoStream.write (tls.js:131:13)
npm ERR! at Socket.ondata (stream.js:38:26)
npm ERR! at Socket.EventEmitter.emit (events.js:88:17)
npm ERR! at TCP.onread (net.js:397:14)
npm ERR! [Error: 1075032064:error:1408D108:SSL routines:SSL3_GET_KEY_EXCHANGE:wrong signature length:../deps/openssl/openssl/ssl/s3_clnt.c:1617:
npm ERR! ]
npm ERR! You may report this log at:
npm ERR! <http://github.com/isaacs/npm/issues>
npm ERR! or email it to:
npm ERR! <npm-@googlegroups.com>

npm ERR! System Linux 3.1.9-28-ARCH+
npm ERR! command "/usr/bin/node" "/usr/bin/npm" "install" "underscore"
npm ERR! cwd /home/bendis
npm ERR! node -v v0.8.2
npm ERR! npm -v 1.1.36
npm ERR! message 1075032064:error:1408D108:SSL routines:SSL3_GET_KEY_EXCHANGE:wrong signature length:../deps/openssl/openssl/ssl/s3_clnt.c:1617:
npm ERR! message
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! /home/bendis/npm-debug.log
npm ERR! not ok code 0

To me it seems like some binary incompatibility between nodejs and openssl. Changing npm registry URL to https://registry.npmjs.org/ (no SSL) helps.


Additional info:
* nodejs version(s): 0.8.1-1, 0.8.2-1
* openssl version(s): 1.0.1.c-1


Steps to reproduce:

1. Install nodejs: pacman -S nodejs
2. Try to install a node.js module: npm install underscore
This task depends upon

Closed by  Bartłomiej Piotrowski (Barthalion)
Sunday, 15 July 2012, 17:49 GMT
Reason for closing:  Fixed
Additional comments about closing:  nodejs 0.8.2-3
Comment by Martin Benda (Bendis) - Wednesday, 11 July 2012, 07:42 GMT
Please see this thread on Raspberry Pi forums: http://www.raspberrypi.org/phpBB3/viewtopic.php?f=34&t=9929
Comment by Alexander F. Rødseth (xyproto) - Sunday, 15 July 2012, 13:29 GMT
Bartłomiej, seems like the "--shared-openssl" configuration option fixes the issue for arm. I just tried building nodejs with it here on x86_64, and everything seems to work fine.
Comment by Bartłomiej Piotrowski (Barthalion) - Sunday, 15 July 2012, 17:47 GMT
I would like to close it with reason "not my problem". This is Arch Linux bugtracker, and Arch Linux ARM != Arch Linux.
If you want me to take care about ARM-related problems, buy a RPI for me, or even better hardware -- I'll assist you in everything.

Yes, I'm not very nice. Alexander is and already posted and tested the possible solution, that's why I'm answering and fixing it, but this is the last time.
Comment by Bartłomiej Piotrowski (Barthalion) - Sunday, 15 July 2012, 17:49 GMT
Ah, and btw everything works here. Underscore installed and works.

Loading...