Compare commits
No commits in common. "61a35a034bc6cad214bffd31d8595a1c5b1b23e0" and "4a48769eeb5dddcf1062a7fecbb4e09247e067e0" have entirely different histories.
61a35a034b
...
4a48769eeb
2 changed files with 1 additions and 17 deletions
|
@ -12,7 +12,6 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|||
- Type for transaction creation errors
|
||||
- Types for Sapling circuit parameters
|
||||
- Function to create transaction
|
||||
- Function to derive distinct transparent spending keys
|
||||
|
||||
### Changed
|
||||
|
||||
|
|
|
@ -101,22 +101,7 @@ genTransparentReceiver i scope xprvk = do
|
|||
ScriptAddress j -> return $ TransparentReceiver P2SH $ fromBinary j
|
||||
_anyOtherKind -> throwIO $ userError "Unsupported transparent address type"
|
||||
|
||||
-- | Generate a transparent receiver
|
||||
genTransparentSecretKey ::
|
||||
Int -- ^ The index of the address to be created
|
||||
-> Scope -- ^ `External` for wallet addresses or `Internal` for change addresses
|
||||
-> XPrvKey -- ^ The transparent private key
|
||||
-> IO TransparentSpendingKey
|
||||
genTransparentSecretKey i scope xprvk = do
|
||||
ioCtx <- createContext
|
||||
let s =
|
||||
case scope of
|
||||
External -> 0
|
||||
Internal -> 1
|
||||
let path = Deriv :/ s :/ fromIntegral i :: DerivPath
|
||||
return $ derivePath ioCtx path xprvk
|
||||
|
||||
-- | decode a Transparent Address in HRF and return a TransparentAddress object
|
||||
-- } decode a Transparent Address in HRF and return a TransparentAddress object
|
||||
decodeTransparentAddress :: BS.ByteString -> Maybe TransparentAddress
|
||||
decodeTransparentAddress taddress = do
|
||||
if BS.length taddress < 34
|
||||
|
|
Loading…
Reference in a new issue