简体   繁体   English

PHP curl到HTTPS是否安全?

[英]Is PHP curl to HTTPS secure?

I read these two things: 我读了这两件事:

  • Sending data from HTTP to HTTPS is not safe. 从HTTP发送数据到HTTPS是不安全的。
  • Curl is as secure as a normal HTTP request. Curl与普通HTTP请求一样安全。

Putting these together, would sending a password to an HTTPS server through curl be insecure? 将它们放在一起,通过curl向HTTPS服务器发送密码会不安全吗? Do both servers need HTTPS in order to be secure? 两个服务器都需要HTTPS才能确保安全吗?

Using curl in php is safe as long as you don't disabled the certificate verification . 只要不禁用证书验证,在php中使用curl 安全的。

Do not touch CURLOPT_SSL_VERIFYHOST and CURLOPT_SSL_VERIFYPEER, their default values are the secure ones. 请勿触摸CURLOPT_SSL_VERIFYHOST和CURLOPT_SSL_VERIFYPEER,其默认值是安全的。

https://secure.php.net/manual/fr/function.curl-setopt.php https://secure.php.net/manual/fr/function.curl-setopt.php

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM