Manager

class OC\Encryption\Manager
Source:lib/private/Encryption/Manager.php#40
Implements:OCP\Encryption\IManager

Properties

protected static property OC\Encryption\Manager::$encryptionModules
Source:lib/private/Encryption/Manager.php#43
Type:array
protected static property OC\Encryption\Manager::$config
Source:lib/private/Encryption/Manager.php#46
Type:\OCP\IConfig
protected static property OC\Encryption\Manager::$logger
Source:lib/private/Encryption/Manager.php#49
Type:\OCP\ILogger
protected static property OC\Encryption\Manager::$l
Source:lib/private/Encryption/Manager.php#52
Type:\OC\Encryption\Il10n
protected static property OC\Encryption\Manager::$rootView
Source:lib/private/Encryption/Manager.php#55
Type:\OC\Files\View
protected static property OC\Encryption\Manager::$util
Source:lib/private/Encryption/Manager.php#58
Type:\OC\Encryption\Util
protected static property OC\Encryption\Manager::$arrayCache
Source:lib/private/Encryption/Manager.php#61
Type:\OC\Memcache\ArrayCache

Methods

public OC\Encryption\Manager::__construct($config, $logger, $l10n, $rootView, $util, $arrayCache)
Source:

lib/private/Encryption/Manager.php#71

Parameters:
public OC\Encryption\Manager::isEnabled()
Check if encryption is enabled
Source:lib/private/Encryption/Manager.php#86
Returns:bool true if enabled, false if not
public OC\Encryption\Manager::isReady()
check if new encryption is ready
Source:lib/private/Encryption/Manager.php#102
Returns:bool
Throws:\OC\ServiceUnavailableException
public OC\Encryption\Manager::isReadyForUser($user)
Source:

lib/private/Encryption/Manager.php#113

Parameters:
  • $user (string)
public OC\Encryption\Manager::registerEncryptionModule($id, $displayName, $callback)
Registers an callback function which must return an encryption module instance
Source:

lib/private/Encryption/Manager.php#137

Parameters:
  • $id (string)
  • $displayName (string)
  • $callback (callable)
Throws:

\OC\Encryption\Exceptions\ModuleAlreadyExistsException

public OC\Encryption\Manager::unregisterEncryptionModule($moduleId)
Unregisters an encryption module
Source:

lib/private/Encryption/Manager.php#160

Parameters:
  • $moduleId (string)
public OC\Encryption\Manager::getEncryptionModules()
get a list of all encryption modules
Source:lib/private/Encryption/Manager.php#169
Returns:array [id => [‘id’ => $id, ‘displayName’ => $displayName, ‘callback’ => callback]]
public OC\Encryption\Manager::getEncryptionModule($moduleId="")
get a specific encryption module
Source:

lib/private/Encryption/Manager.php#180

Parameters:
  • $moduleId (string)
Returns:

\OCP\Encryption\IEncryptionModule

Throws:

\OC\Encryption\Exceptions\ModuleDoesNotExistsException

protected OC\Encryption\Manager::getDefaultEncryptionModule()
get default encryption module
Source:lib/private/Encryption/Manager.php#200
Returns:\OCP\Encryption\IEncryptionModule
Throws:\OC\Encryption\Exceptions\ModuleDoesNotExistsException
public OC\Encryption\Manager::setDefaultEncryptionModule($moduleId)
set default encryption module Id
Source:

lib/private/Encryption/Manager.php#221

Parameters:
  • $moduleId (string)
Returns:

bool

public OC\Encryption\Manager::getDefaultEncryptionModuleId()
get default encryption module Id
Source:lib/private/Encryption/Manager.php#237
Returns:string
public OC\Encryption\Manager::setupStorage()
Add storage wrapper
Source:lib/private/Encryption/Manager.php#244
protected OC\Encryption\Manager::isKeyStorageReady()
check if key storage is ready
Source:lib/private/Encryption/Manager.php#258
Returns:bool