This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8" standalone="yes"?> | |
<ISO_4217 Pblshd="October 1, 2021"> | |
<CcyTbl> | |
<CcyNtry> | |
<CtryNm>AFGHANISTAN</CtryNm> | |
<CcyNm>Afghani</CcyNm> | |
<Ccy>AFN</Ccy> | |
<CcyNbr>971</CcyNbr> | |
<CcyMnrUnts>2</CcyMnrUnts> | |
</CcyNtry> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
update=2023.12.29-release+689 | |
container=$(docker ps -a |grep xahau|cut -d " " -f 1) | |
build=$(docker exec -it $container /opt/xahaud/bin/xahaud -q --version|rev|cut -d "+" -f 1|rev|sed 's/[^0-9]*//g') | |
docker exec -it $container sh -c "curl https://build.xahau.tech/$update > /opt/xahaud/bin/new" | |
docker exec -it $container chmod +x /opt/xahaud/bin/new | |
newbuild=$(docker exec -it $container /opt/xahaud/bin/new -q --version|rev|cut -d "+" -f 1|rev|sed 's/[^0-9]*//g') | |
if [[ "$newbuild" -lt "$build" ]]; then | |
echo "Not OK, $build gt $newbuild" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { generate, utils, signAndSubmit } from 'xrpl-accountlib' | |
for (let i = 0; i < 20; i++) { | |
const account = generate.familySeed({ algorithm: 'ed25519' }) | |
console.log(`${account.address}\t${account.secret.familySeed}\t${account.keypair.privateKey}`) | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { derive, utils, signAndSubmit } from 'xrpl-accountlib' | |
import { TxData } from 'xrpl-txdata' | |
import { XrplClient } from 'xrpl-client' | |
import { xpop, setEndpoints as xpopEndpoints } from 'xpop' | |
import fetch from 'node-fetch' | |
// The above needs: | |
// npm install xrpl-accountlib xrpl-txdata xrpl-client xpop node-fetch | |
const account = derive.familySeed('s....secret') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/// Based on: https://gist.github.com/N3TC4T/a20fb528931ed009ebdd708be4938748 | |
import { derive, utils, signAndSubmit, } from "xrpl-accountlib" | |
import { XrplClient } from "xrpl-client" | |
import { decodeAccountID } from "ripple-address-codec" | |
import { TxData } from 'xrpl-txdata' | |
// const wss = [ 'wss://testnet.xrpl-labs.com', 'wss://s.altnet.rippletest.net:51233', ] | |
const wss = [ 'wss://s.devnet.rippletest.net:51233/' ] | |
const client = new XrplClient(wss) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Assumptions: | |
# - Ubuntu 22.04 | |
# - Docker CE | |
# - IPv6 only environment | |
# - Using netplan for IPv6 addressing | |
# - IPv6 /64 assigned to host | |
# - UFW in use (and DNS to be allowed) - otherwise skip the ufw config | |
# (The above is the Hetzner default) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// This script mass burns & mass (async) mints using B2M | |
// The script takes Sequence, etc. into account & auto-recovers | |
// if Sequence is no longer in sync due to a missed/fallen out tx. | |
import { derive, utils, signAndSubmit } from "xrpl-accountlib" | |
import WebSocket from 'ws' | |
import { XrplClient } from "xrpl-client" | |
import fetch from "node-fetch" | |
import ReconnectingWebSocket from "reconnecting-websocket" | |
import { EventEmitter } from 'node:events' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Reworked (2) version of https://github.com/RichardAH/xrpl-tools/blob/master/validator-address-tool/vatool.js | |
// Testnet faucet: | |
// curl -X POST -H 'content-type:application/json' --data '{"destination":"ryyyyyyyyyyyyyyy", "xrpAmount": "1010" }' https://faucet.altnet.rippletest.net/accounts | |
// Run: | |
// node index.mjs pxxxxxxxxxxxxxxxx ryyyyyyyyyyyyyyyyyyyyy wss://testnet.xrpl-labs.com | |
// ^^ Validator key ^^ Rekey to (address) ^^ Optional: node, default: ws://localhost:6005 | |
import { codec as RAC } from 'ripple-address-codec' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sample output: | |
>> xumm2.6-feecalc-as-is.js | |
┌──────────┬─────────┬─────────┬─────────┬─────────┬─────────┬─────────┬─────────┬─────────┬─────────┐ | |
│ (index) │ 0 │ 1 │ 2 │ 3 │ 4 │ 5 │ 6 │ 7 │ 8 │ | |
├──────────┼─────────┼─────────┼─────────┼─────────┼─────────┼─────────┼─────────┼─────────┼─────────┤ | |
│ input │ 10 │ 12 │ 24 │ 100 │ 500 │ 1200 │ 10000 │ 20000 │ 50000 │ | |
│ -------- │ '-----' │ '-----' │ '-----' │ '-----' │ '-----' │ '-----' │ '-----' │ '-----' │ '-----' │ | |
│ base │ '12' │ '12' │ '24' │ '100' │ '500' │ '1200' │ '10000' │ '20000' │ '50000' │ | |
│ medium │ '14' │ '14' │ '28' │ '118' │ '592' │ '1419' │ '11715' │ '23200' │ '56498' │ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { derive, utils, signAndSubmit } from "xrpl-accountlib" | |
import { XrplClient } from "xrpl-client" | |
const account = derive.familySeed("... FAMILY SEED OF ACCOUNT TO SIGN FINISH TX WITH ...") | |
const tipbotAccount = 'rPEPPER7kfTD9w2To4CQk6UCfuHM9c6GDY' | |
const xrplTime = Math.round(new Date() / 1000) - 946684800 | |
const client = new XrplClient() | |
const networkInfo = await utils.txNetworkAndAccountValues(client, account) |