rebrand(lethean): update branding, ports, and config for Lethean blockchain

- Coin: Zano → Lethean, ticker: ZAN/ZANO → LTHN
- Ports: 11211 → 36941 (mainnet RPC), 46941 (testnet RPC)
- Wallet: 11212 → 36944/46944
- Address prefix: iTHN
- URLs: zano.org → lethean.io
- Explorer links: explorer.lthn.io

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
Claude 2026-04-01 22:24:13 +01:00
parent 5984cb63cb
commit 909bff2dd9
No known key found for this signature in database
GPG key ID: AF404715446AEB41
32 changed files with 4714 additions and 145 deletions

84
Dockerfile Normal file
View file

@ -0,0 +1,84 @@
# Production pool server: builds native deps then runs the mining pool.
# Requires Redis and MySQL at runtime (see docker-compose or env config).
#
# Build context must be the parent directory (zano-upstream/), e.g.:
# docker build -f zano-nodejs-pool/Dockerfile -t lethean-pool .
#
# Runtime env:
# REDIS_HOST, REDIS_PORT — Redis connection
# MYSQL_HOST, MYSQL_USER, MYSQL_PASS, MYSQL_DB — MySQL connection
# (or mount a config.json over /app/config.json)
FROM node:22 AS builder
# Native build dependencies for cryptonote-util and other C++ addons
RUN apt-get update && apt-get install -y --no-install-recommends \
build-essential \
python3 \
python3-pip \
libboost-system-dev \
libboost-date-time-dev \
libboost-thread-dev \
libboost-serialization-dev \
libboost-iostreams-dev \
libboost-locale-dev \
libzmq3-dev \
&& rm -rf /var/lib/apt/lists/*
WORKDIR /workspace
# Build the local cryptonote-util dependency first
COPY blockchain/ ./blockchain/
RUN mkdir -p blockchain/build/release/src/config
COPY blockchain/build/release/src/config/currency_config.h \
blockchain/build/release/src/config/currency_config.h
COPY zano-node-util/package.json zano-node-util/package-lock.json ./zano-node-util/
COPY zano-node-util/binding.gyp zano-node-util/main.cc zano-node-util/index.js ./zano-node-util/
RUN ln -sf /workspace/blockchain /workspace/zano-node-util/Lethean
RUN cd zano-node-util && npm ci && npm rebuild --build-from-source
# Build the pool itself
COPY zano-nodejs-pool/package.json zano-nodejs-pool/package-lock.json ./zano-nodejs-pool/
# Rewrite the local dep path so npm resolves the already-built addon
RUN cd zano-nodejs-pool && \
node -e " \
const fs = require('fs'); \
const pkg = JSON.parse(fs.readFileSync('package.json', 'utf8')); \
pkg.dependencies['cryptonote-util'] = 'file:../zano-node-util'; \
if (pkg.optionalDependencies) { \
pkg.optionalDependencies['lethean-util'] = 'file:../zano-node-util'; \
} \
fs.writeFileSync('package.json', JSON.stringify(pkg, null, 2)); \
"
RUN cd zano-nodejs-pool && npm ci --ignore-scripts
# Rebuild native addons explicitly after all sources are present
RUN cd zano-nodejs-pool && npm rebuild
COPY zano-nodejs-pool/ ./zano-nodejs-pool/
# Production image — keep build tools out
FROM node:22-slim
RUN apt-get update && apt-get install -y --no-install-recommends \
libboost-system1.74.0 \
libboost-date-time1.74.0 \
libboost-thread1.74.0 \
libboost-serialization1.74.0 \
libboost-iostreams1.74.0 \
libboost-locale1.74.0 \
libzmq5 \
&& rm -rf /var/lib/apt/lists/*
WORKDIR /app
COPY --from=builder /workspace/zano-nodejs-pool ./
COPY --from=builder /workspace/zano-node-util /workspace/zano-node-util
# Stratum port and HTTP API port
EXPOSE 5555
EXPOSE 8117
CMD ["node", "init.js"]

View file

@ -12,13 +12,13 @@ worker - Does regular processing of statistics and sends status e-mails for non-
```
API listens on port 8001, remoteShare listens on 8000
Xmrpool.net (The reference implementation) uses the following setup:
* https://xmrpool.net is hosted on its own server, as the main website is a static frontend
* https://api.xmrpool.net hosts api, remoteShare, longRunner, payments, blockManager, worker, as these must all be hosted with access to the same LMDB database.
A typical deployment uses the following setup:
* The main pool website is a static frontend hosted on its own server
* The API server hosts api, remoteShare, longRunner, payments, blockManager, worker, as these must all have access to the same LMDB database.
Sample Caddyfile for API:
```text
https://api.xmrpool.net {
https://api.pool.lethean.io {
proxy /leafApi 127.0.0.1:8000
proxy / 127.0.0.1:8001
cors
@ -40,16 +40,16 @@ Server Requirements
Pre-Deploy
----------
* If you're planning on using e-mail, you'll want to setup an account at https://mailgun.com (It's free for 10k e-mails/month!), so you can notify miners. This also serves as the backend for password reset emails, along with other sorts of e-mails from the pool, including pool startup, pool Monerod daemon lags, etc so it's highly suggested!
* If you're planning on using e-mail, you'll want to setup an account at https://mailgun.com (It's free for 10k e-mails/month!), so you can notify miners. This also serves as the backend for password reset emails, along with other sorts of e-mails from the pool, including pool startup, daemon lags, etc so it's highly suggested!
* Pre-Generate the wallets, or don't, it's up to you! You'll need the addresses after the install is complete, so I'd suggest making sure you have them available. Information on suggested setups are found below.
* If you're going to be offering PPS, PLEASE make sure you load the pool wallet with XMR before you get too far along. Your pool will trigger PPS payments on its own, and fairly readily, so you need some float in there!
* If you're going to be offering PPS, PLEASE make sure you load the pool wallet with LTHN before you get too far along. Your pool will trigger PPS payments on its own, and fairly readily, so you need some float in there!
* Make a non-root user, and run the installer from there!
Deployment via Installer
------------------------
1. Add your user to `/etc/sudoers`, this must be done so the script can sudo up and do it's job. We suggest passwordless sudo. Suggested line: `<USER> ALL=(ALL) NOPASSWD:ALL`. Our sample builds use: `pooldaemon ALL=(ALL) NOPASSWD:ALL`
2. Run the [deploy script](https://raw.githubusercontent.com/Snipa22/nodejs-pool/master/deployment/deploy.bash) as a **NON-ROOT USER**. This is very important! This script will install the pool to whatever user it's running under! Also. Go get a coffee, this sucker bootstraps the monero installation.
2. Run the [deploy script](https://raw.githubusercontent.com/letheanVPN/lethean-nodejs-pool/master/deployment/deploy.bash) as a **NON-ROOT USER**. This is very important! This script will install the pool to whatever user it's running under! Also. Go get a coffee, this sucker bootstraps the Lethean daemon installation.
3. Once it's complete, change as `config.json` appropriate. It is pre-loaded for a local install of everything, running on 127.0.0.1. This will work perfectly fine if you're using a single node setup. You'll also want to set `bind_ip` to the external IP of the pool server, and `hostname` to the resolvable hostname for the pool server. `pool_id` is mostly used for multi-server installations to provide unique identifiers in the backend. You will also want to run: source ~/.bashrc This will activate NVM and get things working for the following pm2 steps.
4. You'll need to change the API endpoint for the frontend code in the `poolui/build/globals.js` and `poolui/build/globals.default.js` -- This will usually be `http(s)://<your server FQDN>/api` unless you tweak caddy!
5. The default database directory `/home/<username>/pool_db/` is already been created during startup. If you change the `db_storage_path` just make sure your user has write permissions for new path. Run: `pm2 restart api` to reload the API for usage.
@ -70,7 +70,7 @@ pm2 restart api
Install Script:
```bash
wget https://raw.githubusercontent.com/hyle-team/zano-nodejs-pool/master/deployment/deploy.bash && chmod +x ./deploy.bash && ./deploy.bash
wget https://raw.githubusercontent.com/letheanVPN/lethean-nodejs-pool/master/deployment/deploy.bash && chmod +x ./deploy.bash && ./deploy.bash
```
Assumptions for the installer
@ -88,19 +88,20 @@ The following raw binaries **MUST BE AVAILABLE FOR IT TO BOOTSTRAP**:
I've confirmed that the default server 16.04 installation has these requirements.
The pool comes pre-configured with values for Monero (XMR), these may need to be changed depending on the exact requirements of your coin. Other coins will likely be added down the road, and most likely will have configuration.sqls provided to overwrite the base configurations for their needs, but can be configured within the frontend as well.
The pool comes pre-configured with values for Lethean (LTHN). Mining algorithm is ProgPoWZ. Wallet addresses use the iTHN prefix with 12 decimal places.
The pool ALSO applies a series of patches: Fluffy Blocks, Additional Open P2P Connections, 128 Txn Bug Fix. If you don't like these, replace the auto-installed monerod fixes!
Testnet ports: Daemon RPC 46941, Wallet RPC 46944, P2P 48081.
Mainnet ports: Daemon RPC 36941, Wallet RPC 36944, P2P 36942.
Wallet Setup
------------
The pool is designed to have a dual-wallet design, one which is a fee wallet, one which is the live pool wallet. The fee wallet is the default target for all fees owed to the pool owner. PM2 can also manage your wallet daemon, and that is the suggested run state.
1. Generate your wallets using `/usr/local/src/monero/build/release/bin/monero-wallet-cli`
2. Make sure to save your regeneration stuff!
1. Generate your wallets using the Lethean CLI wallet (`lethean-wallet-cli`)
2. Make sure to save your seed phrase and keys!
3. For the pool wallet, store the password in a file, the suggestion is `~/wallet_pass`
4. Change the mode of the file with chmod to 0400: `chmod 0400 ~/wallet_pass`
5. Start the wallet using PM2: `pm2 start /usr/local/src/monero/build/release/bin/monero-wallet-rpc -- --rpc-bind-port 18082 --password-file ~/wallet_pass --wallet-file <Your wallet name here> --disable-rpc-login --trusted-daemon`
5. Start the wallet RPC using PM2: `pm2 start lethean-wallet-rpc -- --rpc-bind-port 46944 --password-file ~/wallet_pass --wallet-file <Your wallet name here> --disable-rpc-login --trusted-daemon`
6. If you don't use PM2, then throw the wallet into a screen and have fun.
Manual Setup
@ -124,7 +125,7 @@ general/emailFrom
SQL import command: sudo mysql pool < ~/nodejs-pool/sample_config.sql (Adjust name/path as needed!)
```
The shareHost configuration is designed to be pointed at wherever the leafApi endpoint exists. For xmrpool.net, we use https://api.xmrpool.net/leafApi. If you're using the automated setup script, you can use: `http://<your IP>/leafApi`, as Caddy will proxy it. If you're just using localhost and a local pool serv, http://127.0.0.1:8000/leafApi will do you quite nicely
The shareHost configuration is designed to be pointed at wherever the leafApi endpoint exists. If you're using the automated setup script, you can use: `http://<your IP>/leafApi`, as Caddy will proxy it. If you're just using localhost and a local pool serv, http://127.0.0.1:8000/leafApi will do you quite nicely
Additional ports can be added as desired, samples can be found at the end of base.sql. If you're not comfortable with the MySQL command line, I highly suggest MySQL Workbench or a similar piece of software (I use datagrip!). Your root MySQL password can be found in `/root/.my.cnf`
@ -230,19 +231,18 @@ PPS Fee Thoughts
If you're considering PPS, I've spoken with [Fireice_UK](https://github.com/fireice-uk/) whom kindly did some math about what you're looking at in terms of requirements to run a PPS pool without it self-imploding under particular risk factors, based on the work found [here](https://arxiv.org/pdf/1112.4980.pdf)
```text
Also I calculated the amount of XMR needed to for a PPS pool to stay afloat. Perhaps you should put them up in the README to stop some spectacular clusterfucks :D:
Also I calculated the amount of LTHN needed to for a PPS pool to stay afloat. Perhaps you should put them up in the README to stop some spectacular clusterfucks :D:
For 1 in 1000000 chance that the pool will go bankrupt: 5% fee -> 1200 2% fee -> 3000
For 1 in 1000000000 chance: 5% fee -> 1800 2% fee -> 4500
```
The developers of the pool have not verified this, but based on our own usage on https://xmrpool.net/ this seems rather reasonable. You should be wary if you're considering PPS and take you fees into account appropriately!
You should be wary if you're considering PPS and take your fees into account appropriately!
Installation/Configuration Assistance
=====================================
If you need help installing the pool from scratch, please have your servers ready, which would be Ubuntu 16.04 servers, blank and clean, DNS records pointed. These need to be x86_64 boxes with AES-NI Available.
Installation assistance is 7 XMR, with a 3 XMR deposit, with remainder to be paid on completion.
Configuration assistance is 4 XMR with a 2 XMR deposit, and includes debugging your pool configurations, ensuring that everything is running, and tuning for your uses/needs.
Installation and configuration assistance may be available through the Lethean community.
SSH access with a sudo-enabled user will be needed, preferably the user that is slated to run the pool.
@ -250,12 +250,12 @@ If you'd like assistance with setting up node-cryptonote-pool, please provide wh
Assistance is not available for frontend customization at this time.
For assistance, please contact Snipa at pool_install@snipanet.com or via IRC at irc.freenode.net in the #monero-pools channel.
For assistance, please visit the Lethean community channels at https://lethean.io
Developer Donations
===================
If you'd like to make a one time donation, the addresses are as follows:
* XMR - 44Ldv5GQQhP7K7t3ZBdZjkPA7Kg7dhHwk3ZM3RJqxxrecENSFx27Vq14NAMAd2HBvwEPUVVvydPRLcC69JCZDHLT2X5a4gr
* LTHN - YOUR_iTHN_DONATION_ADDRESS_HERE
* BTC - 114DGE2jmPb5CP2RGKZn6u6xtccHhZGFmM
* AEON - WmtvM6SoYya4qzkoPB4wX7FACWcXyFPWAYzfz7CADECgKyBemAeb3dVb3QomHjRWwGS3VYzMJAnBXfUx5CfGLFZd1U7ssdXTu
@ -264,6 +264,6 @@ Credits
[Zone117x](https://github.com/zone117x) - Original [node-cryptonote-pool](https://github.com/zone117x/node-cryptonote-pool) from which, the stratum implementation has been borrowed.
[Mesh00](https://github.com/mesh0000) - Frontend build in Angular JS [XMRPoolUI](https://github.com/mesh0000/poolui)
[Mesh00](https://github.com/mesh0000) - Frontend build in Angular JS [PoolUI](https://github.com/mesh0000/poolui)
[Wolf0](https://github.com/wolf9466/)/[OhGodAGirl](https://github.com/ohgodagirl) - Rebuild of node-multi-hashing with AES-NI [node-multi-hashing](https://github.com/Snipa22/node-multi-hashing-aesni)

View file

@ -1,10 +1,13 @@
{
"zano": {
"funcFile": "./lib/coins/zano.js",
"paymentFile": "./payment_systems/zano.js",
"lethean": {
"funcFile": "./lib/coins/lethean.js",
"paymentFile": "./payment_systems/lethean.js",
"sigDigits": 1000000000000,
"name": "Zano",
"name": "Lethean",
"shortCode": "LTHN",
"mixIn": 4,
"shortCode": "ZANO"
"addressPrefix": "iTHN",
"decimalPlaces": 12,
"algorithm": "ProgPoWZ"
}
}

75
config-lethean.json Normal file
View file

@ -0,0 +1,75 @@
{
"pool_id": 0,
"bind_ip": "127.0.0.1",
"hostname": "pool.lethean.io",
"coin": "lethean",
"db_storage_path": "data/pool_db",
"redis": {
"host": "127.0.0.1",
"port": 6379,
"auth": null
},
"mysql": {
"connectionLimit": 20,
"host": "127.0.0.1",
"database": "lethean_pool",
"user": "pool",
"password": "CHANGE_ME"
},
"daemon": {
"address": "127.0.0.1",
"port": 46941,
"_comment_port": "Lethean testnet RPC port; mainnet would be 36941",
"p2p_port": 48081,
"_comment_p2p": "Lethean testnet P2P port; mainnet would be 36942"
},
"wallet": {
"address": "127.0.0.1",
"port": 46944,
"_comment_port": "Lethean testnet wallet RPC port; mainnet would be 36944"
},
"pool": {
"address": "YOUR_iTHN_POOL_WALLET_ADDRESS_HERE",
"_comment_address": "Replace with your iTHN... Lethean wallet address",
"targetTime": 120,
"hashrateWindow": 600,
"updateInterval": 5,
"difficulty": 100000,
"trustedSharesCount": 30,
"blockRefreshInterval": 1000,
"minerTimeout": 900,
"maxTransactionAmount": 0,
"minPaymentThreshold": 0.5,
"denominationUnit": 1000000000000,
"paymentInterval": 120,
"maxAddresses": 50,
"slushMiningEnabled": false
},
"ports": [
{
"port": 5555,
"difficulty": 50000,
"desc": "Low difficulty (ProgPoWZ)",
"portType": "pplns",
"hidden": false
},
{
"port": 7777,
"difficulty": 500000,
"desc": "High difficulty (ProgPoWZ)",
"portType": "pplns",
"hidden": false
}
],
"api": {
"port": 8117,
"blocks": 30,
"hashrateWindow": 600
},
"charts": {
"pool": {
"hashrate": { "enabled": true, "updateInterval": 60, "stepInterval": 1800, "maximumPeriod": 86400 },
"workers": { "enabled": true, "updateInterval": 60, "stepInterval": 1800, "maximumPeriod": 86400 }
}
}
}

View file

@ -1,14 +1,28 @@
{
"pool_id": 0,
"bind_ip": "127.0.0.1",
"hostname": "testpool.com",
"hostname": "pool.lethean.io",
"db_storage_path": "CHANGEME",
"coin": "zano",
"coin": "lethean",
"mysql": {
"connectionLimit": 20,
"host": "127.0.0.1",
"database": "pool",
"database": "lethean_pool",
"user": "pool",
"password": "98erhfiuehw987fh23d"
"password": "CHANGE_ME"
},
"daemon": {
"address": "127.0.0.1",
"port": 46941,
"_comment": "Lethean testnet RPC; mainnet = 36941"
},
"wallet": {
"address": "127.0.0.1",
"port": 46944,
"_comment": "Lethean testnet wallet RPC; mainnet = 36944"
},
"pool": {
"address": "YOUR_iTHN_POOL_WALLET_ADDRESS_HERE",
"_comment": "Replace with your iTHN... Lethean wallet address"
}
}

View file

@ -2,7 +2,7 @@
<script src="https://cdnjs.cloudflare.com/ajax/libs/socket.io/1.7.3/socket.io.min.js"></script>
<script>
// set-up a connection between the client and the server
var socket = io.connect('https://api.xmrpool.net/');
var socket = io.connect('https://api.pool.lethean.io/');
// let's assume that the client page, once rendered, knows what room it wants to join

View file

@ -177,10 +177,10 @@ INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES
INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES ('pool', 'trustMin', '20', 'int', 'Minimum level of miner trust');
INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES ('pool', 'trustPenalty', '30', 'int', 'Number of shares that must be successful to be trusted, reset to this value if trust share is broken');
INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES ('pool', 'retargetTime', '60', 'int', 'Time between difficulty retargets');
INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES ('daemon', 'address', '127.0.0.1', 'string', 'Zano Daemon RPC IP');
INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES ('daemon', 'port', '11211', 'int', 'Zano Daemon RPC Port');
INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES ('wallet', 'address', '127.0.0.1', 'string', 'Zano Daemon RPC Wallet IP');
INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES ('wallet', 'port', '11212', 'int', 'Zano Daemon RPC Wallet Port');
INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES ('daemon', 'address', '127.0.0.1', 'string', 'Lethean Daemon RPC IP');
INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES ('daemon', 'port', '46941', 'int', 'Lethean Daemon RPC Port');
INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES ('wallet', 'address', '127.0.0.1', 'string', 'Lethean Daemon RPC Wallet IP');
INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES ('wallet', 'port', '46944', 'int', 'Lethean Daemon RPC Wallet Port');
INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES ('rpc', 'https', 'false', 'bool', 'Enable RPC over SSL');
INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES ('pool', 'maxDifficulty', '500000000000', 'int', 'Maximum difficulty for VarDiff');
INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES ('pool', 'minDifficulty', '1000', 'int', 'Minimum difficulty for VarDiff');
@ -191,17 +191,17 @@ INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES
INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES ('payout', 'pplnsFee', '.6', 'float', 'Fee charged for the usage of the PPLNS pool');
INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES ('payout', 'propFee', '.7', 'float', 'Fee charged for the usage of the proportial pool');
INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES ('payout', 'soloFee', '.4', 'float', 'Fee charged for usage of the solo mining pool');
INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES ('payout', 'exchangeMin', '5', 'float', 'Minimum XMR balance for payout to exchange/payment ID');
INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES ('payout', 'walletMin', '.3', 'float', 'Minimum XMR balance for payout to personal wallet');
INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES ('payout', 'devDonation', '3', 'float', 'Donation to XMR core development');
INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES ('payout', 'exchangeMin', '5', 'float', 'Minimum LTHN balance for payout to exchange/payment ID');
INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES ('payout', 'walletMin', '.3', 'float', 'Minimum LTHN balance for payout to personal wallet');
INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES ('payout', 'devDonation', '3', 'float', 'Donation to Lethean core development');
INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES ('payout', 'poolDevDonation', '3', 'float', 'Donation to pool developer');
INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES ('payout', 'denom', '.000001', 'float', 'Minimum balance that will be paid out to.');
INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES ('payout', 'blocksRequired', '60', 'int', 'Blocks required to validate a payout before it''s performed.');
INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES ('general', 'sigDivisor', '1000000000000', 'int', 'Divisor for turning coin into human readable amounts ');
INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES ('payout', 'feesForTXN', '10', 'int', 'Amount of XMR that is left from the fees to pay miner fees.');
INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES ('payout', 'maxTxnValue', '250', 'int', 'Maximum amount of XMR to send in a single transaction');
INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES ('payout', 'shapeshiftPair', 'xmr_btc', 'string', 'Pair to use in all shapeshift lookups for auto BTC payout');
INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES ('general', 'coinCode', 'XMR', 'string', 'Coincode to be loaded up w/ the shapeshift getcoins argument.');
INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES ('payout', 'feesForTXN', '10', 'int', 'Amount of LTHN that is left from the fees to pay miner fees.');
INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES ('payout', 'maxTxnValue', '250', 'int', 'Maximum amount of LTHN to send in a single transaction');
INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES ('payout', 'shapeshiftPair', 'lthn_btc', 'string', 'Pair to use in all shapeshift lookups for auto BTC payout');
INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES ('general', 'coinCode', 'LTHN', 'string', 'Coin code used for exchange lookups.');
INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES ('general', 'allowBitcoin', 'false', 'bool', 'Allow the pool to auto-payout to BTC via ShapeShift');
INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES ('payout', 'exchangeRate', '0', 'float', 'Current exchange rate');
INSERT INTO pool.config (module, item, item_value, item_type, Item_desc) VALUES ('payout', 'bestExchange', 'xmrto', 'string', 'Current best exchange');

View file

@ -30,7 +30,7 @@ sudo debconf-set-selections <<< "mysql-server mysql-server/root_password_again p
echo -e "[client]\nuser=root\npassword=$ROOT_SQL_PASS" | sudo tee /root/.my.cnf
sudo DEBIAN_FRONTEND=noninteractive apt-get -y install git python-virtualenv python3-virtualenv curl ntp build-essential screen cmake pkg-config libboost-all-dev libevent-dev libunbound-dev libminiupnpc-dev libunwind8-dev liblzma-dev libldns-dev libexpat1-dev libgtest-dev mysql-server lmdb-utils libzmq3-dev
cd ~
git clone https://github.com/hyle-team/zano-nodejs-pool.git # Change this depending on how the deployment goes.
git clone https://github.com/letheanVPN/lethean-nodejs-pool.git # Change this depending on how the deployment goes.
cd /usr/src/gtest
sudo cmake .
sudo make
@ -38,8 +38,8 @@ sudo mv libg* /usr/lib/
cd ~
sudo systemctl enable ntp
cd /usr/local/src
sudo git clone --recursive https://github.com/hyle-team/zano.git
cd zano
sudo git clone --recursive https://github.com/letheanVPN/lethean.git
cd lethean
sudo git checkout master
sudo mkdir build
sudo cd build
@ -48,25 +48,25 @@ sudo make -j$(nproc)
cd ~
export LC_ALL=C
unset LANGUAGE
POOL_WALLET=`/usr/local/src/zano/build/release/src/simplewallet --generate-new-wallet "/home/$CURUSER/zano.wallet" --password "$WALLET_PASSWORD" | grep "Generated new wallet" | awk '{ print $4 }'`
echo "$WALLET_PASSWORD" > "/home/$CURUSER/zano.wallet.passwd"
echo "Generated a new wallet $POOL_WALLET in /home/$CURUSER/zano.wallet with the password in /home/$CURUSER/zano.wallet.passwd."
POOL_WALLET=`/usr/local/src/lethean/build/release/src/simplewallet --generate-new-wallet "/home/$CURUSER/lethean.wallet" --password "$WALLET_PASSWORD" | grep "Generated new wallet" | awk '{ print $4 }'`
echo "$WALLET_PASSWORD" > "/home/$CURUSER/lethean.wallet.passwd"
echo "Generated a new wallet $POOL_WALLET in /home/$CURUSER/lethean.wallet with the password in /home/$CURUSER/lethean.wallet.passwd."
echo "!!! PLEASE BACK IT UP !!!"
sudo screen -S zano -dm bash -c "/usr/local/src/zano/build/release/src/zanod"
sudo screen -S simplewallet -dm bash -c "/usr/local/src/zano/build/release/src/simplewallet --wallet-file /home/$CURUSER/zano.wallet --password `cat /home/$CURUSER/zano.wallet.passwd` --rpc-bind-port 11212"
sudo screen -S lethean -dm bash -c "/usr/local/src/lethean/build/release/src/letheand"
sudo screen -S simplewallet -dm bash -c "/usr/local/src/lethean/build/release/src/simplewallet --wallet-file /home/$CURUSER/lethean.wallet --password `cat /home/$CURUSER/lethean.wallet.passwd` --rpc-bind-port 46942"
curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.0/install.sh | bash
source ~/.nvm/nvm.sh
nvm install v8.9.3
cd ~/zano-nodejs-pool
cd ~/lethean-nodejs-pool
npm install
npm install -g pm2
openssl req -subj "/C=IT/ST=Pool/L=Daemon/O=Mining Pool/CN=mining.pool" -newkey rsa:2048 -nodes -keyout cert.key -x509 -out cert.pem -days 36500
mkdir ~/pool_db/
cp config_example.json config.json
sed -r "s/(\"db_storage_path\": ).*/\1\"\/home\/$CURUSER\/pool_db\/\",/ ; s/(\"bind_ip\": ).*/\1\"$SERVER_IP\",/ ; s/(\"hostname\": ).*/\1\"$SERVER_IP\",/" config_example.json > config.json
sed -i "s/localhost/$SERVER_IP/g" /home/$CURUSER/zano-nodejs-pool/frontend/app/globals.js
sed -i "s/localhost/$SERVER_IP/g" /home/$CURUSER/zano-nodejs-pool/frontend/app/globals.default.js
cd ~/zano-nodejs-pool/frontend
sed -i "s/localhost/$SERVER_IP/g" /home/$CURUSER/lethean-nodejs-pool/frontend/app/globals.js
sed -i "s/localhost/$SERVER_IP/g" /home/$CURUSER/lethean-nodejs-pool/frontend/app/globals.default.js
cd ~/lethean-nodejs-pool/frontend
npm install
./node_modules/bower/bin/bower update
./node_modules/gulp/bin/gulp.js build
@ -86,7 +86,7 @@ sudo chown -R root:www-data /etc/caddy
sudo mkdir /etc/ssl/caddy
sudo chown -R www-data:root /etc/ssl/caddy
sudo chmod 0770 /etc/ssl/caddy
sudo cp ~/zano-nodejs-pool/deployment/caddyfile /etc/caddy/Caddyfile
sudo cp ~/lethean-nodejs-pool/deployment/caddyfile /etc/caddy/Caddyfile
sudo chown www-data:www-data /etc/caddy/Caddyfile
sudo chmod 444 /etc/caddy/Caddyfile
sudo sh -c "sed 's/ProtectHome=true/ProtectHome=false/' init/linux-systemd/caddy.service > /etc/systemd/system/caddy.service"
@ -98,7 +98,7 @@ sudo systemctl start caddy.service
rm -rf $CADDY_DOWNLOAD_DIR
cd ~
sudo env PATH=$PATH:`pwd`/.nvm/versions/node/v8.9.3/bin `pwd`/.nvm/versions/node/v8.9.3/lib/node_modules/pm2/bin/pm2 startup systemd -u $CURUSER --hp `pwd`
cd ~/zano-nodejs-pool
cd ~/lethean-nodejs-pool
sudo chown -R $CURUSER. ~/.pm2
echo "Installing pm2-logrotate in the background!"
pm2 install pm2-logrotate &
@ -118,8 +118,8 @@ pm2 start init.js --name=remoteShare --log-date-format="YYYY-MM-DD HH:mm Z" -- -
pm2 start init.js --name=longRunner --log-date-format="YYYY-MM-DD HH:mm Z" -- --module=longRunner
pm2 start init.js --name=pool --log-date-format="YYYY-MM-DD HH:mm Z" -- --module=pool
pm2 start init.js --name=api --log-date-format="YYYY-MM-DD HH:mm Z" -- --module=api
bash ~/zano-nodejs-pool/deployment/install_lmdb_tools.sh
cd ~/zano-nodejs-pool/sql_sync/
bash ~/lethean-nodejs-pool/deployment/install_lmdb_tools.sh
cd ~/lethean-nodejs-pool/sql_sync/
env PATH=$PATH:`pwd`/.nvm/versions/node/v8.9.3/bin node sql_sync.js
echo "You're setup! Please read the rest of the readme for the remainder of your setup and configuration. These steps include: Setting your Fee Address, Pool Address, Global Domain, and the Mailgun setup!"
printf "\n"

View file

@ -4,7 +4,7 @@
<!--[if IE 8]> <html lang="en" ng-app="pooladmin" class="no-js lt-ie9" manifest="app.manifest"> <![endif]-->
<!--[if gt IE 8]><!--> <html lang="en" ng-app="pooladmin" class="no-js" manifest="app.manifest"> <!--<![endif]-->
<head>
<title>Zano pool</title>
<title>Lethean pool</title>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0">

View file

@ -10,15 +10,15 @@
<md-list flex>
<md-list-item>
<h3> Owed </h3>
<p class="text-right">{{stats.owed | toXMR | number }} ZANO</p>
<p class="text-right">{{stats.owed | toXMR | number }} LTHN</p>
</md-list-item>
<md-list-item>
<h3> Paid </h3>
<p class="text-right">{{stats.paid | toXMR | number }} ZANO</p>
<p class="text-right">{{stats.paid | toXMR | number }} LTHN</p>
</md-list-item>
<md-list-item>
<h3> Mined </h3>
<p class="text-right">{{stats.mined | toXMR | number}} ZANO</p>
<p class="text-right">{{stats.mined | toXMR | number}} LTHN</p>
</md-list-item>
<md-list-item>
<h3> Shares </h3>
@ -45,12 +45,12 @@
<h4> Height<h2>{{ pool_wallet.height | number }}</h2></h4>
</div>
<div flex>
<h4> Unlocked<h2>{{ pool_wallet.unlocked | toXMR }} ZANO</h2></h4>
<h4> Unlocked<h2>{{ pool_wallet.unlocked | toXMR }} LTHN</h2></h4>
</div>
</div>
<div flex layout="column" layout-gt-xs="row">
<div flex>
<h4> Balance<h2>{{ pool_wallet.balance | toXMR }} ZANO</h2></h4>
<h4> Balance<h2>{{ pool_wallet.balance | toXMR }} LTHN</h2></h4>
</div>
<div flex>
<h4> Timestamp<h2>{{ pool_wallet.ts | date }}</h2></h4>
@ -76,8 +76,8 @@
<tbody md-body>
<tr md-row ng-repeat="history in pool_wallet_history">
<td md-cell><p class="md-body-2">{{history.height | number}}</p></td>
<td md-cell><p class="md-body-2">{{history.balance | toXMR }} ZANO</p></td>
<td md-cell><p class="md-body-2">{{history.unlocked | toXMR }} ZANO</p></td>
<td md-cell><p class="md-body-2">{{history.balance | toXMR }} LTHN</p></td>
<td md-cell><p class="md-body-2">{{history.unlocked | toXMR }} LTHN</p></td>
<td md-cell>
<h3 class="md-body-2" am-time-ago="history.ts"></h3>
<md-tooltip>
@ -119,8 +119,8 @@
</md-tooltip>
</td>
<td md-cell ng-bind-html="payment.hash | hashToLink: 'tx'"></td>
<td md-cell><p class="md-body-2">{{payment.value | toXMR}} ZANO</p></td>
<td md-cell><p class="md-body-2">{{payment.fee | toXMR }} ZANO</p></td>
<td md-cell><p class="md-body-2">{{payment.value | toXMR}} LTHN</p></td>
<td md-cell><p class="md-body-2">{{payment.fee | toXMR }} LTHN</p></td>
<td md-cell><p class="md-body-2">{{payment.mixins}}</p></td>
<td md-cell><p class="md-body-2">{{payment.payees}}</p></td>
</tr>

View file

@ -19,8 +19,8 @@
<tr md-row ng-repeat="worker in pool_workers | orderBy: workersOrder">
<td md-cell>{{worker.hashRate | toHashRate}}</td>
<td md-cell>{{worker.address}}</td>
<td md-cell>{{worker.paid | toXMR}} ZANO</td>
<td md-cell>{{worker.due | toXMR }} ZANO</td>
<td md-cell>{{worker.paid | toXMR}} LTHN</td>
<td md-cell>{{worker.due | toXMR }} LTHN</td>
<td md-cell>{{worker.totalHashes | number }}</td>
<td md-cell>{{worker.goodShares | number }}</td>
<td md-cell>{{worker.badShares | number }}</td>

View file

@ -4,7 +4,7 @@ angular.module('pool.globals', [])
.factory('GLOBALS', function() {
return {
pool_name: "ZanoPool",
pool_name: "LetheanPool",
api_url : 'http://localhost:8001',
api_refresh_interval: 5000
};

View file

@ -4,7 +4,7 @@ angular.module('pool.globals', [])
.factory('GLOBALS', function() {
return {
pool_name: "ZanoPool",
pool_name: "LetheanPool",
api_url : 'http://localhost:8001',
api_refresh_interval: 5000
};

View file

@ -4,7 +4,7 @@
<!--[if IE 8]> <html lang="en" ng-app="poolui" class="no-js lt-ie9" manifest="app.manifest"> <![endif]-->
<!--[if gt IE 8]><!--> <html lang="en" ng-app="poolui" class="no-js" manifest="app.manifest"> <!--<![endif]-->
<head>
<title>Zano pool</title>
<title>Lethean pool</title>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0">
@ -28,7 +28,7 @@
<div class="container" layout="row" flex>
<md-sidenav md-is-locked-open="menuOpen" md-component-id="left" md-whiteframe="4" class="sidenav">
<md-toolbar class="logo">
<h1 class="md-toolbar-tools">Zano pool <i class="md-caption">beta</i></h1>
<h1 class="md-toolbar-tools">Lethean pool <i class="md-caption">beta</i></h1>
</md-toolbar>
<md-list>
<md-list-item>

View file

@ -64,7 +64,7 @@
</md-list-item>
<md-list-item>
<p> Block Reward </p>
<p class="text-right">{{lastBlock[pooltype].value | toXMR | number:10}} ZANO</p>
<p class="text-right">{{lastBlock[pooltype].value | toXMR | number:10}} LTHN</p>
</md-list-item>
<md-list-item>
<p> Time Found </p>
@ -165,10 +165,10 @@
</div>
<div flex layout="column" layout-gt-xs="row">
<div flex>
<h5> Total Due<h2>{{miner.amtDue | toXMR | number:10}} ZANO</h2></h5>
<h5> Total Due<h2>{{miner.amtDue | toXMR | number:10}} LTHN</h2></h5>
</div>
<div flex>
<h5> Total Paid<h2>{{miner.amtPaid | toXMR | number:10}} ZANO</h2></h5>
<h5> Total Paid<h2>{{miner.amtPaid | toXMR | number:10}} LTHN</h2></h5>
</div>
</div>
</div>

View file

@ -34,7 +34,7 @@
</md-tooltip>
</td>
<td md-cell><p class="md-body-2">{{payment.pt}}</p></td>
<td md-cell><p class="md-body-2">{{payment.amount | toXMR }} ZANO</p></td>
<td md-cell><p class="md-body-2">{{payment.amount | toXMR }} LTHN</p></td>
<td md-cell ng-bind-html="payment.txnHash | hashToLink: 'tx'"></td>
<td md-cell><p class="md-body-2">{{payment.mixin}}</p></td>
</tr>

View file

@ -23,7 +23,7 @@ app.controller('FAQCtrl', function($scope, $location, $anchorScroll, $sce, dataS
},
{
title: "How do I start mining?",
answer: $sce.trustAsHtml("You can start mining today if you have a computer that sits idle. Zano can be mined on CPUs, GPU's or even a raspberry PI. To start mining you need to find the right mining software for your hardware and get going.<br/><br/>Read <a hred='#/help/getting_started'>Getting Started</a> for more details.")
answer: $sce.trustAsHtml("You can start mining today if you have a computer that sits idle. Lethean can be mined on CPUs, GPU's or even a raspberry PI. To start mining you need to find the right mining software for your hardware and get going.<br/><br/>Read <a hred='#/help/getting_started'>Getting Started</a> for more details.")
},
{
title: "What is pool mining?",
@ -49,19 +49,19 @@ app.controller('FAQCtrl', function($scope, $location, $anchorScroll, $sce, dataS
},
{
title: "Payout thresholds?",
answer: $sce.trustAsHtml("Payout threshold is the minimum amount that needs to be earned before the pool pays out to your wallet. Since transactions in Zano have a significant miner fees, it's cost effective to set a higher payout threshold for your pool. The minimum value for this is usually 0.3 ZANO.<br/><br/>To change your payment threshold, click the wrench after you login via \"Login\" button on the top right.<br/><br/>You could also adjust your payout threshold to regulate your payout schedule etc daily/weekly etc depending on your hash rate.")
answer: $sce.trustAsHtml("Payout threshold is the minimum amount that needs to be earned before the pool pays out to your wallet. Since transactions in Lethean have a significant miner fees, it's cost effective to set a higher payout threshold for your pool. The minimum value for this is usually 0.3 LTHN.<br/><br/>To change your payment threshold, click the wrench after you login via \"Login\" button on the top right.<br/><br/>You could also adjust your payout threshold to regulate your payout schedule etc daily/weekly etc depending on your hash rate.")
},
{
title: "Why hasn't my \"Total Due\" amount increased?",
answer: $sce.trustAsHtml("Sometimes, the Zano blockchain will take a couple days for a new block to be found. Although you are contributing shares, the pool cannot guarantee your earnings until they are static.")
answer: $sce.trustAsHtml("Sometimes, the Lethean blockchain will take a couple days for a new block to be found. Although you are contributing shares, the pool cannot guarantee your earnings until they are static.")
},
{
title: "Getting paid in BTC",
answer: $sce.trustAsHtml("nodejs-pool supports direct payments to btc. This is done by using the shapeshift API to convert your XMR and send them to a BTC wallet.<br/><br/>To configure BTC payments please have a look at <a href='#/help/getting_started'>Getting Started</a> command line samples.")
answer: $sce.trustAsHtml("nodejs-pool supports direct payments to btc. This is done by using the shapeshift API to convert your LTHN and send them to a BTC wallet.<br/><br/>To configure BTC payments please have a look at <a href='#/help/getting_started'>Getting Started</a> command line samples.")
},
{
title: "Payments to exchanges/markets?",
answer: $sce.trustAsHtml("Direct payment to exchange / pool wallets are supported. The only primary difference when using this method is that the minimum payout threshold is higher and usually a defaults to 3XMR.")
answer: $sce.trustAsHtml("Direct payment to exchange / pool wallets are supported. The only primary difference when using this method is that the minimum payout threshold is higher and usually defaults to 3 LTHN.")
},
{
title: "IP Banning?",
@ -79,7 +79,7 @@ app.controller('FAQCtrl', function($scope, $location, $anchorScroll, $sce, dataS
"Mining":[
{
title: "Hardware?",
answer: $sce.trustAsHtml("Zano is an AISC resistant cryptocurrency, that means it should be cost prohibitive to mine monero with an FGPA/AISC allowing desktop grade hardware to keep its share in the network hashrate and earnings.<br/><br/><a href='http://monerobechmarks.byethost5.com/' target='_new'>http://monerobechmarks.byethost5.com/</a> is a list of community collected hashrate results ordered by hardware, but be careful as some entries may not be accurate.")
answer: $sce.trustAsHtml("Lethean uses the ProgPoWZ mining algorithm, which is designed to be ASIC resistant and optimised for GPU mining. Desktop-grade hardware can earn a fair share of the network hashrate and earnings.")
},
{
title: "Software?",
@ -89,11 +89,11 @@ app.controller('FAQCtrl', function($scope, $location, $anchorScroll, $sce, dataS
"Support":[
{
title: "Chat Support",
answer: $sce.trustAsHtml("ZANO is an ASIC resistant cryptocurrency, that means it should be cost prohibitive to mine Zano with an FGPA/AISC allowing desktop grade hardware to keep its share in the network hashrate and earnings.<br/><br/><a href='http://monerobechmarks.byethost5.com/' target='_new'>http://monerobechmarks.byethost5.com/</a> is a list of community collected hashrate results ordered by hardware, but be careful as some entries may not be accurate.")
answer: $sce.trustAsHtml("For support, visit the Lethean community channels at <a href='https://lethean.io' target='_new'>lethean.io</a>.")
},
{
title: "Interesting links.",
answer: $sce.trustAsHtml("<a href='http://reddit.com/r/moneromining' target='_new'>http://reddit.com/r/moneromining/</a><br/><a href='http://monero.stackexchange.com/' target='_new'>http://monero.stackexchange.com/</a>")
answer: $sce.trustAsHtml("<a href='https://lethean.io' target='_new'>https://lethean.io</a><br/><a href='https://github.com/letheanVPN' target='_new'>https://github.com/letheanVPN</a>")
}
]
}

View file

@ -19,8 +19,8 @@
</md-toolbar>
<md-card-content>
<p class="panel-subtitle">Both online wallets and hardware wallets have their pros and cons.</p>
<p class="panel-subtitle"><a href="https://www.mymonero.com" target="_blank">MyMonero</a> : MyMonero is an online wallet maintained by the core monero team, so while safe is still suceptable to hacks.</p>
<p class="panel-subtitle"><a href="https://getmonero.org/2016/12/22/monero-core-gui-beta-released.html" target="_blank">Monero GUI Wallet</a> : The safest way to safely store and secure your XMR, although it would be your responsibility to keep your XMR Safe.</p>
<p class="panel-subtitle"><a href="https://lethean.io" target="_blank">Lethean CLI Wallet</a> : The Lethean command-line wallet is the most secure way to store and manage your LTHN.</p>
<p class="panel-subtitle">Wallet addresses start with <b>iTHN</b> and use 12 decimal places. Mining algorithm: <b>ProgPoWZ</b>.</p>
</md-card-content>
</md-card>
<md-card>

View file

@ -22,7 +22,7 @@
</md-input-container>
<div ng-messages="thresholdForm.threshold.$error" multiple>
<div ng-message="min">
This value cannot be lower than {{min_wallet_payout | toXMR}} XMR
This value cannot be lower than {{min_wallet_payout | toXMR}} LTHN
</div>
</div>
<p>The pool will pay out to your wallet once your total due exceeds the payment threshold</p>

View file

@ -45,15 +45,15 @@
</md-list-item>
<md-list-item>
<p>Minimum payout (Wallet)</p>
<p class="text-right">{{config.min_wallet_payout | toXMR}} ZANO</p>
<p class="text-right">{{config.min_wallet_payout | toXMR}} LTHN</p>
</md-list-item>
<md-list-item>
<p>Minimum payout (BTC)</p>
<p class="text-right">{{config.min_btc_payout | toXMR}} ZANO</p>
<p class="text-right">{{config.min_btc_payout | toXMR}} LTHN</p>
</md-list-item>
<md-list-item>
<p>Minimum payout (Exchange)</p>
<p class="text-right">{{config.min_exchange_payout | toXMR}} ZANO</p>
<p class="text-right">{{config.min_exchange_payout | toXMR}} LTHN</p>
</md-list-item>
<md-list-item>
<p>Block Maturity Depth</p>

View file

@ -30,8 +30,8 @@
</md-tooltip>
</td>
<td md-cell ng-bind-html="payment.hash | hashToLink: 'tx'"></td>
<td md-cell><p class="md-body-2">{{payment.value | toXMR}} ZANO</p></td>
<td md-cell><p class="md-body-2">{{payment.fee | toXMR }} ZANO</p></td>
<td md-cell><p class="md-body-2">{{payment.value | toXMR}} LTHN</p></td>
<td md-cell><p class="md-body-2">{{payment.fee | toXMR }} LTHN</p></td>
<td md-cell><p class="md-body-2">{{payment.mixins}}</p></td>
<td md-cell><p class="md-body-2">{{payment.payees}}</p></td>
</tr>

View file

@ -2,6 +2,13 @@
angular.module('utils.strings', [])
.filter('toLTHN', function() {
return function(amount) {
return amount / 1000000000000; // 12 decimal places for LTHN
};
})
// Keep toXMR as alias for backwards compatibility with templates
.filter('toXMR', function() {
return function(amount) {
return amount / 1000000000000;
@ -22,7 +29,7 @@ angular.module('utils.strings', [])
.filter('hashToLink', function($sce) {
return function(hash, type) {
var str = (hash == undefined) ? 'none' : "<a class=\"md-body-2\" target=\"_new\" href=\"https://xmrchain.net/"+type+"/" + hash + "\">" + hash + "</a>";
var str = (hash == undefined) ? 'none' : "<a class=\"md-body-2\" target=\"_new\" href=\"https://explorer.lethean.io/"+type+"/" + hash + "\">" + hash + "</a>";
return $sce.trustAsHtml(str);
};
})

View file

@ -1,5 +1,5 @@
{
"name": "xmrpoolui",
"name": "lethean-pool-ui",
"private": true,
"dependencies": {
"angular": "~1.6.1",

View file

@ -1,6 +1,6 @@
{
"name": "xmrpoolui",
"description": "UI for XMR Pool.net",
"name": "lethean-pool-ui",
"description": "UI for Lethean (LTHN) Mining Pool",
"repository": "",
"license": "?",
"devDependencies": {

View file

@ -1,4 +1,4 @@
# Monero Pool frontend
# Lethean Pool frontend
### AngularJS based UI for [nodejs-pool](https://github.com/Snipa22/nodejs-pool)
@ -36,7 +36,7 @@ $ npm install # runs everything, serve from ./build
* Miner graph colour picker
### Support
* I'm usually on #monero-pools so drop me a line if you need help with something or have a feature request.
* Visit the Lethean community channels for help or feature requests.
#### Coffee :P ?
42yCGRP2p6bZzMjJxKpJtTFRz2x3X3eBYD97T17zdxC9NiGNWafCaU54MKWBZkHb9AVb4XBgcjkPGW8hjQyBM2vMMvVCzTj

View file

@ -6,13 +6,13 @@ const cluster = require('cluster');
const async = require("async");
const debug = require("debug")("api");
const btcValidator = require('wallet-address-validator');
const zanoUtil = require('zano-util');
const letheanUtil = require('lethean-util');
const bodyParser = require('body-parser');
const jwt = require('jsonwebtoken'); // used to create, sign, and verify tokens
const crypto = require('crypto');
const cors = require('cors');
let addressBase58Prefix = zanoUtil.address_decode(new Buffer(global.config.pool.address));
let addressBase58Prefix = letheanUtil.address_decode(new Buffer(global.config.pool.address));
let threadName = "";
if (cluster.isMaster) {
@ -182,8 +182,8 @@ app.get('/config', function (req, res) {
// Pool APIs
app.get('/pool/address_type/:address', function (req, res) {
let address = req.params.address;
if (addressBase58Prefix === zanoUtil.address_decode(new Buffer(address))) {
res.json({valid: true, address_type: 'XMR'});
if (addressBase58Prefix === letheanUtil.address_decode(new Buffer(address))) {
res.json({valid: true, address_type: 'LTHN'});
} else if (btcValidator.validate(this.address) && global.config.general.allowBitcoin) {
res.json({valid: true, address_type: 'BTC'});
} else {
@ -551,18 +551,18 @@ adminRoutes.use(function (req, res, next) {
let token = req.body.token || req.query.token || req.headers['x-access-token'];
if (token) {
jwt.verify(token, global.config.api.secKey, function (err, decoded) {
if (decoded.admin !== 1) {
// Verify token validity BEFORE checking admin flag
if (err) {
return res.json({success: false, msg: 'Failed to authenticate token.'});
}
if (!decoded || decoded.admin !== 1) {
return res.status(403).send({
success: false,
msg: 'You are not an admin.'
});
}
if (err) {
return res.json({success: false, msg: 'Failed to authenticate token.'});
} else {
req.decoded = decoded;
next();
}
req.decoded = decoded;
next();
});
} else {

View file

@ -1,13 +1,13 @@
"use strict";
const bignum = require('bignum');
const zanoUtil = require('zano-util');
const letheanUtil = require('lethean-util');
const crypto = require('crypto');
function Coin(data){
this.bestExchange = global.config.payout.bestExchange;
this.data = data;
this.coinDevAddress = ""; // Developer Address
this.poolDevAddress = ""; // Snipa Address
this.coinDevAddress = ""; // Lethean developer fund address (set if dev donation enabled)
this.poolDevAddress = ""; // Pool operator address (set if pool dev donation enabled)
this.blockedAddresses = [
this.coinDevAddress,
@ -17,6 +17,8 @@ function Coin(data){
this.exchangeAddresses = [
]; // These are addresses that MUST have a paymentID to perform logins with.
// Lethean address prefix: iTHN...
// These values must match the Lethean blockchain address encoding
this.prefix = 197;
this.intPrefix = 0x3678;
@ -73,27 +75,27 @@ function Coin(data){
this.validateAddress = function(address){
// This function should be able to be called from the async library, as we need to BLOCK ever so slightly to verify the address.
address = new Buffer(address);
return zanoUtil.is_address_valid(address);
return letheanUtil.is_address_valid(address);
};
this.convertBlob = function(blobBuffer){
return zanoUtil.convert_blob(blobBuffer);
return letheanUtil.convert_blob(blobBuffer);
};
this.getBlockID = function(blockBuffer){
return zanoUtil.get_id_hash(blockBuffer);
return letheanUtil.get_id_hash(blockBuffer);
};
this.getPoWHash = function(convertedBlob, nonce, height) {
return zanoUtil.get_pow_hash(convertedBlob, nonce, height);
return letheanUtil.get_pow_hash(convertedBlob, nonce, height);
};
this.getHashFromBlockTemplateWithExtra = function(blockTemplate, extraData) {
return zanoUtil.get_hash_from_block_template_with_extra(blockTemplate, extraData);
return letheanUtil.get_hash_from_block_template_with_extra(blockTemplate, extraData);
};
this.getBlobFromBlockTemplate = function(blockTemplate, extraData, nonce) {
return zanoUtil.get_blob_from_block_template(blockTemplate, extraData, nonce);
return letheanUtil.get_blob_from_block_template(blockTemplate, extraData, nonce);
};
this.BlockTemplate = function(template) {

View file

@ -36,15 +36,15 @@ let paymentQueue = async.queue(function (paymentDetails, callback) {
}
}
if (paymentDetails.hasOwnProperty('payment_id')) {
console.log("Payment made to " + paymentDetails.destinations[0].address + " with PaymentID: " + paymentDetails.payment_id + " For: " + global.support.coinToDecimal(paymentDetails.destinations[0].amount) + " XMR with a " + global.support.coinToDecimal(body.result.fee) + " XMR Mining Fee");
console.log("Payment made to " + paymentDetails.destinations[0].address + " with PaymentID: " + paymentDetails.payment_id + " For: " + global.support.coinToDecimal(paymentDetails.destinations[0].amount) + " LTHN with a" + global.support.coinToDecimal(body.result.fee) + " LTHN Mining Fee");
return callback(body.result);
} else {
if (transferFunc === 'transfer') {
console.log("Payment made out to multiple people, total fee: " + global.support.coinToDecimal(body.result.fee) + " XMR");
console.log("Payment made out to multiple people, total fee: " + global.support.coinToDecimal(body.result.fee) + " LTHN");
}
let intCount = 0;
paymentDetails.destinations.forEach(function (details) {
console.log("Payment made to: " + details.address + " For: " + global.support.coinToDecimal(details.amount) + " XMR");
console.log("Payment made to: " + details.address + " For: " + global.support.coinToDecimal(details.amount) + " LTHN");
intCount += 1;
if (intCount === paymentDetails.destinations.length) {
return callback(body.result);

View file

@ -205,8 +205,8 @@ let VarDiff = (function () {
})();
function Miner(id, login, pass, ipAddress, startingDiff, messageSender, protoVersion, portType, port, agent) {
// Username Layout - <address in BTC or XMR>.<Difficulty>
// Password Layout - <password>.<miner identifier>.<payment ID for XMR>
// Username Layout - <address in BTC or LTHN>.<Difficulty>
// Password Layout - <password>.<miner identifier>.<payment ID for LTHN>
// Default function is to use the password so they can login. Identifiers can be unique, payment ID is last.
// If there is no miner identifier, then the miner identifier is set to the password
// If the password is x, aka, old-logins, we're not going to allow detailed review of miners.

4385
package-lock.json generated Normal file

File diff suppressed because it is too large Load diff

View file

@ -1,11 +1,11 @@
{
"name": "zano-nodejs-pool",
"name": "lethean-nodejs-pool",
"version": "0.0.1",
"description": "Fairly simple universal Zano pool",
"description": "Fairly simple universal Lethean pool",
"main": "init.js",
"repository": {
"type": "git",
"url": "https://github.com/hyle-team/zano-nodejs-pool.git"
"url": "https://github.com/letheanVPN/lethean-nodejs-pool.git"
},
"author": "Alexander Blair",
"license": "MIT",
@ -20,7 +20,7 @@
"concat-stream": "^1.6.0",
"cors": "^2.8.1",
"crypto": "0.0.3",
"cryptonote-util": "git://github.com/hyle-team/zano-node-util.git",
"cryptonote-util": "file:../zano-node-util",
"debug": "2.5.1",
"express": "4.14.0",
"jsonwebtoken": "^7.2.1",
@ -44,8 +44,7 @@
"zmq": "^2.15.3"
},
"optionalDependencies": {
"cryptonight-hashing": "git+https://github.com/MoneroOcean/node-cryptonight-hashing.git",
"multi-hashing": "git+https://github.com/hyle-team/node-multi-hashing-aesni.git",
"zano-util": "git://github.com/hyle-team/zano-node-util.git"
"multi-hashing": "file:../node-multi-hashing-aesni",
"lethean-util": "file:../zano-node-util"
}
}

View file

@ -109,15 +109,15 @@
"item": "address",
"item_value": "127.0.0.1",
"item_type": "string",
"Item_desc": "Zano Daemon RPC IP"
"Item_desc": "Lethean Daemon RPC IP"
},
{
"id": 16,
"module": "daemon",
"item": "port",
"item_value": "11211",
"item_value": "46941",
"item_type": "int",
"Item_desc": "Zano Daemon RPC Port"
"Item_desc": "Lethean Daemon RPC Port"
},
{
"id": 17,
@ -125,15 +125,15 @@
"item": "address",
"item_value": "127.0.0.1",
"item_type": "string",
"Item_desc": "Zano Daemon RPC Wallet IP"
"Item_desc": "Lethean Daemon RPC Wallet IP"
},
{
"id": 18,
"module": "wallet",
"item": "port",
"item_value": "11212",
"item_value": "46944",
"item_type": "int",
"Item_desc": "Zano Daemon RPC Wallet Port"
"Item_desc": "Lethean Daemon RPC Wallet Port"
},
{
"id": 21,
@ -221,7 +221,7 @@
"item": "exchangeMin",
"item_value": "5",
"item_type": "float",
"Item_desc": "Minimum XMR balance for payout to exchange/payment ID"
"Item_desc": "Minimum LTHN balance for payout to exchange/payment ID"
},
{
"id": 33,
@ -229,7 +229,7 @@
"item": "walletMin",
"item_value": ".3",
"item_type": "float",
"Item_desc": "Minimum XMR balance for payout to personal wallet"
"Item_desc": "Minimum LTHN balance for payout to personal wallet"
},
{
"id": 34,
@ -237,7 +237,7 @@
"item": "devDonation",
"item_value": "5",
"item_type": "float",
"Item_desc": "Donation to XMR core development"
"Item_desc": "Donation to Lethean core development"
},
{
"id": 35,
@ -285,7 +285,7 @@
"item": "feesForTXN",
"item_value": "10",
"item_type": "int",
"Item_desc": "Amount of XMR that is left from the fees to pay miner fees."
"Item_desc": "Amount of LTHN that is left from the fees to pay miner fees."
},
{
"id": 41,
@ -293,13 +293,13 @@
"item": "maxTxnValue",
"item_value": "250",
"item_type": "int",
"Item_desc": "Maximum amount of XMR to send in a single transaction"
"Item_desc": "Maximum amount of LTHN to send in a single transaction"
},
{
"id": 42,
"module": "payout",
"item": "shapeshiftPair",
"item_value": "xmr_btc",
"item_value": "lthn_btc",
"item_type": "string",
"Item_desc": "Pair to use in all shapeshift lookups for auto BTC payout"
},
@ -307,7 +307,7 @@
"id": 43,
"module": "general",
"item": "coinCode",
"item_value": "XMR",
"item_value": "LTHN",
"item_type": "string",
"Item_desc": "Coincode to be loaded up w/ the shapeshift getcoins argument."
},