ow.sec
$sec.$sec
$sec.$sec(aRepo, dBucket, dLockSecret, aMainSecret, aFile) : $sec
Shortcut for acessing ow.sec.SBuckets given aMainSecret and, optionally, aRepo. A default dBucket and the corresponding dLockSecret can be provided.
$sec.close
$sec.close() : Object
Close the current repository.
$sec.encSKey
$sec.encSKey(aKey) : String
Given aKey will return the encrypted version of it with the current main sectet for the repo.
Example:
$sec("test", "b1", $sec("test", __, __, "Password123").encSKey("Password1"), "Password123", "test.yml").set("mysecret", { l:"l", p:"p" })
// ...
$sec("test", "b1", $sec("test", __, __, "Password123").encSKey("Password1"), "Password123", "test.yml").get("mysecret")
$sec.get
$sec.get(aKey, aBucket, aLockSecret) : Object
Retrieves the secret object/string for aKey. Optionally you can provide a specific aBucket and the corresponding aLockSecret.
$sec.getBucket
$sec.getBucket(aBucket, aLockSecret) : String
Retrieves a encrypted SBucket string to be transported to another SBucket repo. Optionally you can provide a specific aBucket and the corresponding aLockSecret.
$sec.getFn
$sec.getFn(aKey, aExtraArgs, aBucket, aLockSecret) : Object
Invokes a function using the secret arguments for aKey with non-secret aExtraArgs map (arguments should have the same name as the function help parameters). Optionally you can provide a specific aBucket and the corresponding aLockSecret.
$sec.getObj
$sec.getObj(aKey, aExtraArgs, aBucket, aLockSecret) : Object
Creates a new instance of an object using the secret arguments for aKey with non-secret aExtraArgs map (arguments should have the same name as the constructor help parameters). Optionally you can provide a specific aBucket and the corresponding aLockSecret.
$sec.list
$sec.list(aBucket, aLockSecret) : Array
Returns a map with a list of all the sBuckets on the current repo. If a specifc sBucket and aLockSecret isn't provide the current sBucket will have an associated array with the list of corresponding keys.
$sec.set
$sec.set(aKey, aObj, aBucket, aLockSecret) : Object
Sets the secret aObj map/string associating it with aKey. Optionally you can provide a specific aBucket and the corresponding aLockSecret.
$sec.setBucket
$sec.setBucket(aBucketString, aBucket, aLockSecret) : String
Sets an encrypted SBucket string transported from another SBucket repo (the aLockSecret should be equal) Optionally you can provide a specific aBucket and the corresponding aLockSecret.
$sec.setFn
$sec.setFn(aKey, aFn, aArgs, aBucket, aLockSecret) : Object
Sets secret aArgs (map with the arguments names on the aFn help)) for calling aFn (string). Optionally you can provide a specific aBucket and the corresponding aLockSecret.
$sec.setObj
$sec.setObj(aKey, aObj, aArgs, aBucket, aLockSecret) : Object
Sets secret aArgs (map with the arguments names on the aObj constructor help)) for constructing aObj (string). Optionally you can provide a specific aBucket and the corresponding aLockSecret.
$sec.unset
$sec.unset(aKey, aBucket, aLockSecret) : Object
Unsets aKey for a SBucket. Optionally you can provide a specific aBucket and the corresponding aLockSecret.
$sec.unsetBucket
$sec.unsetBucket(aBucket)
Unsets aBucket from the current repo.
$sec.unsetRepo
$sec.unsetRepo()
Unsets the current repo.
ow.sec.closeMainSBuckets
ow.sec.closeMainSBuckets()
Close the default SBucket.
ow.sec.closeSBuckets
ow.sec.closeSBuckets(aRepo, aFile)
Close a previously open aRepo SBucket.
ow.sec.openMainSBuckets
ow.sec.openMainSBuckets(aMainSecret)
Open the default SBucket using aMainSecret.
ow.sec.openSBuckets
ow.sec.openSBuckets(aRepo, aMainSecret, aFile)
Opens aRepo SBucket using aMainSecret.
ow.sec.purgeMainSBuckets
ow.sec.purgeMainSBuckets()
Purge the default SBucket.
ow.sec.purgeSBuckets
ow.sec.purgeSBuckets(aRepo, aFile)
Purge aRepo SBucket.
ow.sec.SBucket.createBucket
ow.sec.SBucket.createBucket(sBucket, aLockSecret)
Creates a sbucket with a specific aLockSecret.
ow.sec.SBucket.destroyBucket
ow.sec.SBucket.destroyBucket(sBucket)
Destroys a sBucket.
ow.sec.SBucket.getBucket
ow.sec.SBucket.getBucket(sBucket, aLockSecret) : String
Given a sbucket and aLockSecret retrieves a string representation of the sbucket.
ow.sec.SBucket.getKeys
ow.sec.SBucket.getKeys(sBucket, aLockSecret, aKey) : Map
Returns a map with a list of all the sBuckets on the current repo. If a specifc sBucket and aLockSecret isn't provide the current sBucket will have an associated array with the list of corresponding keys.
ow.sec.SBucket.getNewFn
ow.sec.SBucket.getNewFn(sBucket, aLockSecret, aKey, defaultArgs)
For the sBucket with aLockSecret will invoke a function and set arguments using aKey.
ow.sec.SBucket.getNewObj
ow.sec.SBucket.getNewObj(sBucket, aLockSecret, aKey, defaultArgs)
For the sBucket with aLockSecret create an object with the arguments in aKey.
ow.sec.SBucket.getSBucket
ow.sec.SBucket.getSBucket() : String
Returns a string representation of the sbucket.
ow.sec.SBucket.getSecret
ow.sec.SBucket.getSecret(sBucket, aLockSecret, aKey) : Map
Given a sbucket and a specific aLockSecret will return the associated aKey.
ow.sec.SBucket.getSecretAs
ow.sec.SBucket.getSecretAs(sBucket, aLockSecret, aEncryptKey, aKey) : Map
Given a sbucket and a specific aLockSecret will return the associated aKey encrypted with aEncryptKey.
ow.sec.SBucket.getSNewFn
ow.sec.SBucket.getSNewFn(Key)
Will invoke a function and set arguments using aKey.
ow.sec.SBucket.getSNewObj
ow.sec.SBucket.getSNewObj(aKey)
Create an object with the arguments in aKey.
ow.sec.SBucket.getSSecret
ow.sec.SBucket.getSSecret(aKey) : Map
Returns the associated aKey value.
ow.sec.SBucket.getSSecretAs
ow.sec.SBucket.getSSecretAs(aEncryptKey, aKey) : Map
Returns the associated aKey encrypted with aEncryptKey.
ow.sec.SBucket.SBucket
ow.sec.SBucket.SBucket(aCh, aMainSecret, sBucket, aLockSecret) : sbucket
Creates a set of sbuckets on aCh using aMainSecret. Defaults, if provided, to sBucket and aLockSecret.
ow.sec.SBucket.setBucket
ow.sec.SBucket.setBucket(sBucket, aLockSecret, aBucketString)
Given a sbucket, aLockSecret will set the sbucket to the provided aBucketString.
ow.sec.SBucket.setNewFn
ow.sec.SBucket.setNewFn(sBucket, aLockSecret, aKey, aFn, args)
For the sBucket with aLockSecret will set aKey to use aFn with the arguments map ($fnDev4Help).
ow.sec.SBucket.setNewObj
ow.sec.SBucket.setNewObj(sBucket, aLockSecret, aKey, aObject, args)
For the sBucket with aLockSecret will set aKey to create aObject with the arguments map ($fnDev4Help).
ow.sec.SBucket.setSBucket
ow.sec.SBucket.setSBucket(aBucketString)
Set the current sbucket to the provided aBucketString.
ow.sec.SBucket.setSecret
ow.sec.SBucket.setSecret(sBucket, aLockSecret, aKey, aObj)
Given a sbucket and aLockSecret will set aKey to aObj (string or map)
ow.sec.SBucket.setSNewFn
ow.sec.SBucket.setSNewFn(aKey, aFn, args)
For the sBucket with aLockSecret will set aKey to use aFn with the arguments map ($fnDev4Help).
ow.sec.SBucket.setSNewObj
ow.sec.SBucket.setSNewObj(aKey, aObject, args)
Will set aKey to create aObject with the arguments map ($fnDev4Help).
ow.sec.SBucket.setSSecret
ow.sec.SBucket.setSSecret(aKey, aObj)
Sets aKey to aObj (string or map)
ow.sec.SBucket.unsetSecret
ow.sec.SBucket.unsetSecret(sBucket, aLockSecret, aKey)
Given a sbucket and aLockSecret will unset aKey.
ow.sec.SBucket.unsetSSecret
ow.sec.SBucket.unsetSSecret(aKey)
Unsets aKey.