mirror of
https://github.com/php-curl-class/php-curl-class.git
synced 2026-08-30 04:01:47 +00:00
Increase uniqueness of Curl::id
Replace `uniqid` by `random_bytes` (#792)
This commit is contained in:
committed by
GitHub
parent
319c1fc285
commit
c9ad23cf5c
+1
-1
@@ -2095,7 +2095,7 @@ class Curl extends BaseCurl
|
||||
$this->setOpts($options);
|
||||
}
|
||||
|
||||
$this->id = uniqid('', true);
|
||||
$this->id = bin2hex(random_bytes(16));
|
||||
|
||||
// Only set default user agent if not already set.
|
||||
if (!array_key_exists(CURLOPT_USERAGENT, $this->options)) {
|
||||
|
||||
Reference in New Issue
Block a user