|
|
@@ -354,7 +354,7 @@ class Socket {
|
|
|
* @param bool $enable enable or disable encryption. Default is true (enable)
|
|
|
* @return bool True on success
|
|
|
* @throws \InvalidArgumentException When an invalid encryption scheme is chosen.
|
|
|
- * @throws \Cake\Network\Error\SocketException When attempting to enable SSL/TLS fails
|
|
|
+ * @throws \Cake\Network\Exception\SocketException When attempting to enable SSL/TLS fails
|
|
|
* @see stream_socket_enable_crypto
|
|
|
*/
|
|
|
public function enableCrypto($type, $clientOrServer = 'client', $enable = true) {
|
|
|
@@ -366,7 +366,7 @@ class Socket {
|
|
|
$enableCryptoResult = stream_socket_enable_crypto($this->connection, $enable, $this->_encryptMethods[$type . '_' . $clientOrServer]);
|
|
|
} catch (\Exception $e) {
|
|
|
$this->setLastError(null, $e->getMessage());
|
|
|
- throw new Error\SocketException($e->getMessage());
|
|
|
+ throw new SocketException($e->getMessage());
|
|
|
}
|
|
|
if ($enableCryptoResult === true) {
|
|
|
$this->encrypted = $enable;
|
|
|
@@ -374,7 +374,7 @@ class Socket {
|
|
|
}
|
|
|
$errorMessage = 'Unable to perform enableCrypto operation on the current socket';
|
|
|
$this->setLastError(null, $errorMessage);
|
|
|
- throw new Error\SocketException($errorMessage);
|
|
|
+ throw new SocketException($errorMessage);
|
|
|
}
|
|
|
|
|
|
}
|