~
Thanks a lot!
Can you trust this service? Is it reliable?
the address creation part from a public key doesn't have that much to trust if you understand what it returns. as for signing part, as i said i am not sure how you can use it to sign this type of transaction. but if there is a way, you can trust it by checking the source code here:
https://github.com/OutCast3k/coinbin/ and making sure to clone the code and run it locally.
an example:
pubkey: 03DB114DE0DC61D5445B801DEAB2D9A32810B7BC5C5CF18CDA31F78827CD5A472F
date and time: 11/29/2019 13:42
the redeem script: 04f0eee05db1752103db114de0dc61d5445b801deab2d9a32810b7bc5c5cf18cda31f78827cd5a4
72fac
if we break it apart it is like this:
04 <- size of the locktime
f0eee05d <- locktime epoch value in little-endial hex = 1575022320 = Friday, November 29, 2019 10:12:00 AM
https://www.epochconverter.com/ (note that the site used my local time which is GMT+03:30)
b1 <- OP_CLV
75 <- OP_DROP
21 <- size of public key = 33 bytes
03db114de0dc61d5445b801deab2d9a32810b7bc5c5cf18cda31f78827cd5a472f <- the public key
ac <- OP_CheckSig
as you can see there isn't any magic going on here. you could create it by hand yourself too!
then you hash this redeem script just like the way you hash your multisig redeem script:
e11a62c5a409aead78491fd34aa15aca58cf2e6d
add P2SH address version byte and encode it with base58:
05e11a62c5a409aead78491fd34aa15aca58cf2e6d(2545c46b=chcksum)
the result is 3NDFa2QeDcRvuCJ1uDGMDMaT2Q8w85ugvn