Bitok v0.3.19.11 “Native Blind” released- Full RPC support for arbitrary script contract construction and validation
- Native Blind (ok-addresses): ECDH-based stealth payments
- Deterministic change for stealth UTXOs
- GUI support for stealth address management
No consensus changes.
1. Full Script Contract RPC SuiteThis release completes the missing pieces required to build, sign, and validate arbitrary custom scripts without template-specific RPCs.
New RPC Commands:buildscriptAssemble scripts from opcode names and hex pushes.
buildscript '["OP_ADD","OP_5","OP_EQUAL"]'
Returns serialized script hex.
No manual hex encoding required.
--------------------------------------------------
setscriptsigInject a custom scriptSig into any transaction input.
Accepts:
- Raw hex
- Array of hex pushes
- Space-separated opcode strings
This is the key missing component.signrawtransaction only auto-signs known templates.
setscriptsig allows arbitrary stack construction for any script.
--------------------------------------------------
getscriptsighashExposes the internal SignatureHash() computation.
Returns the exact 32-byte digest that OP_CHECKSIG verifies.
Required for:
- Custom scripts mixing logic and signatures
- External/offline signing workflows
- Non-standard signature flows
--------------------------------------------------
decodescriptsigDecodes a scriptSig in context of its scriptPubKey.
Stack elements are labeled by role (signature, pubkey, preimage, push_0, etc.) based on script classification.
--------------------------------------------------
verifyscriptpairFull scriptSig + scriptPubKey verification against a real transaction context.
Unlike validatescript, this supports OP_CHECKSIG.
Includes failure diagnostics.
--------------------------------------------------
Complete Custom Script WorkflowAny arbitrary contract can now follow:
buildscript
→ createrawtransaction
→ signrawtransaction
→ sendrawtransaction
→ createrawtransaction (spend)
→ getscriptsighash
→ setscriptsig
→ verifyscriptpair
→ sendrawtransaction
No special-case RPCs required.
--------------------------------------------------
Script Classificationanalyzescript continues to classify scripts automatically:
- Arithmetic
- Bitwise
- Hashlock
- Multisig
- CAT-based covenant
- Splice
This allows introspection without per-template RPC methods.
--------------------------------------------------------------------
2. Native Blind — ok-AddressesThis release implements ECDH-based stealth addresses at the wallet layer.
No consensus change required. Transactions remain standard P2PKH + OP_RETURN.
DesignReceiver generates:
- Scan keypair
- Spend keypair
Stealth address encodes both compressed pubkeys:
- Prefix: ok
- Version byte: 0x01
- Payload: scan_pubkey || spend_pubkey
- Base58Check encoded
--------------------------------------------------
SendingSender:
- Generates ephemeral keypair
- Performs ECDH with receiver scan pubkey
- Derives shared secret via double-SHA256
- Computes one-time destination:
P_dest = P_spend + Hash(shared_secret) * G
- Creates normal P2PKH output to derived address
- Embeds ephemeral compressed pubkey in OP_RETURN with prefix 0x06
--------------------------------------------------
ReceivingWallet scanning logic:
- Checks OP_RETURN outputs for 0x06 + 33-byte pubkey
- Performs ECDH with scan private key
- Derives expected destination
- If matched, computes:
p_dest = p_spend + Hash(shared_secret) mod n
Derived private key is imported into the keystore automatically.
No manual step required.
--------------------------------------------------
What This Achieves- Each payment to the same ok-address produces a unique on-chain destination
- Outside observers cannot link payments to the published stealth address
- Receiver does not need to be online
--------------------------------------------------------------------
Deterministic Change for Stealth UTXOsWhen spending stealth-derived outputs, change is deterministically derived:
change_priv = SHA256d(spend_secret || "stealth_change" || index)
- Ensures recoverability from exported stealth secret
- No dependency on address pool backups
- Rescan recovers derived change keys automatically
--------------------------------------------------------------------
RPC Commands for Stealth- getnewstealthaddress
- liststealthaddresses
- sendtostealthaddress
- decodestealthaddress
- exportstealthaddress
- importstealthaddress
- getstealthephemerals
- getstealthtxids
Import performs two-pass scan to recover stealth payments and deterministic change.
--------------------------------------------------------------------
GUI UpdatesGUI wallet upgraded with:
- ok-address generation
- Stealth transaction sending
- Stealth address management

--------------------------------------------------------------------
Compatibility- Wallet-layer feature only
- Fully backward compatible
- Standard transaction format
- No hard fork
- No consensus rule changes
Bitok continues building on the 0.3.19 execution model, restoring original opcode capability and expanding contract tooling without altering consensus.
Repository updated. Documentation included.
https://github.com/elvisjedusor/bitok
https://github.com/elvisjedusor/bitok/releases/tag/0.3.19.11
https://bitokd.run/download
https://bitokd.run/docs