Crypto::Secret Add protection method stubs
This commit is contained in:
parent
c00910a6b2
commit
de11459cb1
@ -1,6 +1,8 @@
|
||||
# Interface to hold sensitive information (often cryptographic keys)
|
||||
#
|
||||
# **Only for direct use by cryptographic library authors**
|
||||
#
|
||||
# For all other applications use a preexisting class that include `Crypto::Secret`
|
||||
@[Experimental]
|
||||
module Crypto::Secret
|
||||
abstract def to_slice : Bytes
|
||||
@ -8,14 +10,26 @@ module Crypto::Secret
|
||||
def readwrite
|
||||
end
|
||||
|
||||
def readwrite
|
||||
yield
|
||||
end
|
||||
|
||||
def readonly
|
||||
end
|
||||
|
||||
def readonly
|
||||
yield
|
||||
end
|
||||
|
||||
def noaccess
|
||||
end
|
||||
|
||||
def noaccess
|
||||
yield
|
||||
end
|
||||
|
||||
def wipe
|
||||
# Todo: implement wiping
|
||||
# Todo: implement wiping. Needs crystal support
|
||||
end
|
||||
|
||||
def wipe
|
Loading…
Reference in New Issue
Block a user