Skip to content

Instantly share code, notes, and snippets.

@Fliktrax
Created March 17, 2020 12:21
Show Gist options
  • Save Fliktrax/f111b10e8019da98a89cd5cd25943af7 to your computer and use it in GitHub Desktop.
Save Fliktrax/f111b10e8019da98a89cd5cd25943af7 to your computer and use it in GitHub Desktop.
<?php
$fp = fopen("https://cloud-messaging.bitrix24.com", "r");
$stream_meta = stream_get_meta_data($fp);
print_r($stream_meta);
?>
Result:
Array
(
[crypto] => Array
(
[protocol] => TLSv1.2
[cipher_name] => ECDHE-RSA-AES128-GCM-SHA256
[cipher_bits] => 128
[cipher_version] => TLSv1.2
)
[timed_out] =>
[blocked] => 1
[eof] =>
[wrapper_data] => Array
(
[0] => HTTP/1.1 200 OK
[1] => Accept-Ranges: bytes
[2] => Cache-control: no-cache="set-cookie"
[3] => Content-Type: text/html
[4] => Date: Tue, 17 Mar 2020 12:16:23 GMT
[5] => ETag: "507df20b-fb"
[6] => Last-Modified: Tue, 16 Oct 2012 23:47:23 GMT
[7] => Server: nginx/1.8.1
[8] => Set-Cookie: AWSELB=C147A12F1E9E03DBCEC7E7D8833235DEC65290501017C774FA1B5A7CD39F42A975BFCFDEF0FB6B68DC20FC101EF1F0B7C225E7A13071C4CE1DCE056DBF16C75841E63330A6;PATH=/;MAX-AGE=86400
[9] => Set-Cookie: AWSELBCORS=C147A12F1E9E03DBCEC7E7D8833235DEC65290501017C774FA1B5A7CD39F42A975BFCFDEF0FB6B68DC20FC101EF1F0B7C225E7A13071C4CE1DCE056DBF16C75841E63330A6;PATH=/;MAX-AGE=86400;SECURE;SAMESITE=None
[10] => Content-Length: 251
[11] => Connection: Close
)
[wrapper_type] => http
[stream_type] => tcp_socket/ssl
[mode] => r
[unread_bytes] => 251
[seekable] =>
[uri] => https://cloud-messaging.bitrix24.com
)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment