class TLS in DRD Agent 8.3
Same name and namespace in other branches
- 4.0.x src/Crypt/Method/TLS.php \Drupal\drd_agent\Crypt\Method\TLS
Provides security over TLS without additional encryption.
Hierarchy
- class \Drupal\drd_agent\Crypt\BaseMethod implements BaseMethodInterface
- class \Drupal\drd_agent\Crypt\Method\TLS
Expanded class hierarchy of TLS
2 string references to 'TLS'
- Base::getMethods in src/
Crypt/ Base.php - Get a list of crypt methods, either just their ids or instances of each.
- TLS::getLabel in src/
Crypt/ Method/ TLS.php - Get the crypt method label.
File
- src/
Crypt/ Method/ TLS.php, line 13
Namespace
Drupal\drd_agent\Crypt\MethodView source
class TLS extends BaseMethod {
/**
* {@inheritdoc}
*/
public function getLabel() : string {
return 'TLS';
}
/**
* {@inheritdoc}
*/
public function getCipher() : bool {
return FALSE;
}
/**
* {@inheritdoc}
*/
public function getPassword() : string {
return FALSE;
}
/**
* {@inheritdoc}
*/
public function isAvailable() : bool {
// TODO: properly find out if the remote site is running on TLD.
return FALSE;
}
/**
* {@inheritdoc}
*/
public function getCipherMethods() : array {
return [];
}
/**
* {@inheritdoc}
*/
public function getIv() : string {
return '';
}
/**
* {@inheritdoc}
*/
public function encrypt(array $args) : string {
return serialize($args);
}
/**
* {@inheritdoc}
*/
public function decrypt($body, $iv) {
/** @noinspection UnserializeExploitsInspection */
return unserialize($body);
}
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
BaseMethod:: |
protected | property | ||
BaseMethod:: |
protected | property | ||
BaseMethod:: |
private | function | Callback to encrypt and decrypt files. | |
BaseMethod:: |
public | function |
Encrypt a file. Overrides BaseMethodInterface:: |
|
BaseMethod:: |
public | function | BaseMethod constructor. | 2 |
TLS:: |
public | function |
Decode, decrypt and unserialize arguments from the other end. Overrides BaseMethodInterface:: |
|
TLS:: |
public | function |
Encrypt and encode any list of arguments. Overrides BaseMethodInterface:: |
|
TLS:: |
public | function |
Get the selected cipher. Overrides BaseMethodInterface:: |
|
TLS:: |
public | function |
Get a list of available cipher methods. Overrides BaseMethodInterface:: |
|
TLS:: |
public | function |
Get an initialiation vector. Overrides BaseMethodInterface:: |
|
TLS:: |
public | function |
Get the crypt method label. Overrides BaseMethodInterface:: |
|
TLS:: |
public | function |
Get the password. Overrides BaseMethodInterface:: |
|
TLS:: |
public | function |
Find out if the crypt method is available. Overrides BaseMethodInterface:: |