to_slice declare protected
This commit is contained in:
parent
13b6c20e7b
commit
1cbb5c7b90
@ -174,7 +174,7 @@ class MySecret
|
||||
# optionally mlock
|
||||
end
|
||||
|
||||
def to_slice(& : Bytes -> Nil)
|
||||
protected def to_slice(& : Bytes -> Nil)
|
||||
# The yielded Slice only needs to be valid within the block
|
||||
# yield Slice.new(pointer, size)
|
||||
ensure
|
||||
|
@ -6,6 +6,7 @@ module Crypto::Secret
|
||||
# * Not locked in memory
|
||||
# * Not access protected
|
||||
# * No guard pages
|
||||
# * Hours of fun
|
||||
class Bidet
|
||||
include Stateless
|
||||
|
||||
|
@ -90,7 +90,7 @@ module Crypto::Secret
|
||||
abstract def readonly
|
||||
abstract def noaccess
|
||||
|
||||
abstract def to_slice(& : Bytes -> Nil)
|
||||
protected abstract def to_slice(& : Bytes -> Nil)
|
||||
abstract def bytesize : Int32
|
||||
|
||||
macro delegate_to_slice(to object)
|
||||
|
Loading…
Reference in New Issue
Block a user