diff --git a/README.md b/README.md index 80753e5..8b07818 100755 --- a/README.md +++ b/README.md @@ -34,15 +34,15 @@ to MyMonero. They include: - new transaction details window. - sending xmr to a subaddress (not receiving nor generating subaddresses for now). -## Testnet version +## Stagenet version (Currently offline) - [http://139.162.32.245:81](http://139.162.32.245:81) -This is Open Monero running on testnet network. You can use it to play around with it. -Since this is testnet version, frequent changes and database resets are expected. Also, +This is Open Monero running on stagenet network. You can use it to play around with it. +Since this is stagenet version, frequent changes and database resets are expected. Also, it is running on cheap vps, which may result in some lag. -If you want some testnet monero, please make issue with your testnet address that you can +If you want some testnet or stagenet monero, please make issue with your stagenet address that you can obtained from Open Monero. ## Screenshot @@ -195,9 +195,9 @@ Command line options ```bash ./openmonero -h - -h [ --help ] [=arg(=1)] (=0) produce help message -t [ --testnet ] [=arg(=1)] (=0) use testnet blockchain + -s [ --stagenet ] [=arg(=1)] (=0) use stagenet blockchain --do-not-relay [=arg(=1)] (=0) does not relay txs to other nodes. useful when testing construction and submiting txs @@ -215,11 +215,12 @@ Before running `openmonero`: Time library used in Open Monero stores there time zone offsets database that it uses. - edit `config/confing.js` file with your settings. Especially set `frontend-url` and `database` connection details. - - set `apiUrl` in `html\js\config.js` and `testnet` flag. Last slash `/` in `apiUrl` is important. - If running backend for testnet network, frontend `testnet` flag must be set to `true`. + - set `apiUrl` in `html\js\config.js` and `nettype` option. Last slash `/` in `apiUrl` is important. + If running backend for testnet or stagenet networks, frontend `nettype` must be set to + 1 - TESTNET or 2 - STAGENET. 0 is for MAINNET. For mainnet, it is set to `false`. - - make sure monero daemon is running and fully sync. If using testnet network, use daemon - with testnet flag! + - make sure monero daemon is running and fully sync. If using testnet or stagenet networks, use monero daemon + with `--testnet` or `--stagenet` flags! To start for mainnet: @@ -237,17 +238,16 @@ To start for stagenet: ./openmonero -s ``` -To start for testnet with non-default location of `config.json` file: +To start for stagenet with non-default location of `config.json` file: ```bash -./openmonero -t -c /path/to/config.json +./openmonero -s -c /path/to/config.json ``` ## API calls -In the below examples, you can change `127.0.0.1:1984` into `139.162.32.245:1984` to -query the testnet open monero instance (assuming its up and working well). +Example calls and their outputs are provided below. #### get_version diff --git a/html/js/cn_util.js b/html/js/cn_util.js index e0331d6..c11d7f5 100755 --- a/html/js/cn_util.js +++ b/html/js/cn_util.js @@ -56,7 +56,7 @@ var cnUtil = (function(initConfig) { } else if (config.nettype === 2 /*stagenet*/) { CRYPTONOTE_PUBLIC_ADDRESS_BASE58_PREFIX = config.addressPrefixStagenet; CRYPTONOTE_PUBLIC_INTEGRATED_ADDRESS_BASE58_PREFIX = config.integratedAddressPrefixStagenet; - CRYPTONOTE_PUBLIC_SUBADDRESS_BASE58_PREFIX = config.subAddressPrefixStagnet; + CRYPTONOTE_PUBLIC_SUBADDRESS_BASE58_PREFIX = config.subAddressPrefixStagenet; } var UINT64_MAX = new JSBigInt(2).pow(64); diff --git a/html/js/config.js b/html/js/config.js index 00238cc..1e10f32 100755 --- a/html/js/config.js +++ b/html/js/config.js @@ -23,7 +23,7 @@ var config = { feePerKB: new JSBigInt('2000000000'),//20^10 - not used anymore, as fee is dynamic. dustThreshold: new JSBigInt('1000000000'),//10^10 used for choosing outputs/change - we decompose all the way down if the receiver wants now regardless of threshold txChargeRatio: 0.5, - defaultMixin: 4, // minimum mixin for hardfork v5 + defaultMixin: 6, // minimum mixin for hardfork v7 is 6 (ring size 7) txChargeAddress: '', idleTimeout: 30, idleWarningDuration: 20, diff --git a/html/js/controllers/send_coins.js b/html/js/controllers/send_coins.js index f8c1fec..7db1e9c 100755 --- a/html/js/controllers/send_coins.js +++ b/html/js/controllers/send_coins.js @@ -45,7 +45,14 @@ thinwalletCtrls.controller('SendCoinsCtrl', function($scope, $http, $q, var view_only = AccountService.isViewOnly(); - var explorerUrl = config.testnet ? config.testnetExplorerUrl : config.mainnetExplorerUrl; + var explorerUrl = ""; + + if (config.nettype == 0) + explorerUrl = config.mainnetExplorerUrl; + else if (config.nettype == 1) + explorerUrl = config.testnetExplorerUrl; + else + explorerUrl = config.stagenetExplorerUrl; // few multiplayers based on uint64_t wallet2::get_fee_multiplier var fee_multiplayers = [1, 4, 20, 166]; diff --git a/html/js/controllers/transaction_details.js b/html/js/controllers/transaction_details.js index 6b6c364..552752c 100644 --- a/html/js/controllers/transaction_details.js +++ b/html/js/controllers/transaction_details.js @@ -52,7 +52,14 @@ thinwalletCtrls.controller('TransactionDetailsCtrl', function ($scope, return; } - var explorerUrl = config.testnet ? config.testnetExplorerUrl : config.mainnetExplorerUrl; + var explorerUrl = ''; + + if (config.nettype == 0) + explorerUrl = config.mainnetExplorerUrl; + else if (config.nettype == 1) + explorerUrl = config.testnetExplorerUrl; + else + explorerUrl = config.stagenetExplorerUrl; var address = AccountService.getAddress(); var view_key = AccountService.getViewKey(); diff --git a/html/partials/send-coins.html b/html/partials/send-coins.html index 36f0fcc..cc40b05 100755 --- a/html/partials/send-coins.html +++ b/html/partials/send-coins.html @@ -55,10 +55,10 @@