2013-10-31 171 views
0

我可以連接到它扔我的瀏覽器,我的意思是我鍵入主機比它要求我的用戶名和通過我輸入它,我在..但.. ..我不能連接到它通過終端使用捲曲。試圖通過終端連接到https

$ curl -v https://.../... -3 --basic -u uname:upass -A Mozilla/5.0 
* About to connect() to ... (#0) 
* Trying ... 
* connected 
* Connected to ... 
* successfully set certificate verify locations: 
* CAfile: nofile 
    CApath: /etc/ssl/certs 
* SSLv3, TLS handshake, Client hello (1): 
* SSLv3, TLS handshake, Server hello (2): 
* SSLv3, TLS handshake, CERT (11): 
* SSLv3, TLS handshake, Server key exchange (12): 
* SSLv3, TLS handshake, Server finished (14): 
* SSLv3, TLS handshake, Client key exchange (16): 
* SSLv3, TLS change cipher, Client hello (1): 
* SSLv3, TLS handshake, Finished (20): 
* SSLv3, TLS change cipher, Client hello (1): 
* SSLv3, TLS handshake, Finished (20): 
* SSL connection using .... 
* Server certificate: 
* subject: OU=Domain Control Validated; CN=... 
* start date: 201 
* expire date: 201 
* subjectAltName: ... matched 
* issuer: C=U 
* SSL certificate verify ok. 
* Server auth using Basic with user 'uname' 
> GET /pls/hun/tlh.lt_reg HTTP/1.1 
> Authorization: Basic thisoneisgood= 
> User-Agent: Mozilla/5.0 
> Host: ... 
> Accept: */* 
> 
* additional stuff not fine transfer.c:1037: 0 0 
* SSLv3, TLS alert, Client hello (1): 
* Empty reply from server 
* Connection #0 to host ... left intact 
curl: (52) Empty reply from server 
* Closing connection #0 
* SSLv3, TLS alert, Client hello (1): 

是什麼問題?

+0

嘗試'--anyauth'而不是'--basic'。你有權訪問服務器的訪問日誌嗎? – keltar

+0

沒有幫助,我沒有訪問日誌。我甚至試圖設置與瀏覽器中相同的標題。我使用Live HTTP標頭獲取標題。 – user2940285

回答

0

問題在於curl,curl的新版本只能在sslv3服務器上運行在sslv2上,所以我不得不使用舊版本的curl重新編譯它,而是編寫-2而不是-3。注意,如果你用這個curl版本編寫-2,你會得到同樣的錯誤... curl不會寫道它不支持sslv2,你必須自己弄清楚它。

0

嘗試驗證您的cURL的版本curl -V,7.24.0有相同的問題,而7.35.0工作正常。