Commit Graph

798 Commits

Author SHA1 Message Date
moneromooo-monero 54a3c19ae2
depends: set several missing build tags 2020-03-16 02:13:50 -05:00
TheCharlatan 2d8b8eb43c
depends: update libsodium to 1.0.18 2020-03-16 02:11:58 -05:00
Lee Clagett 3068408d04
Fixed string_ref usage bug in epee::from_hex::vector 2020-03-16 02:10:55 -05:00
Howard Chu 6537668224
"Fix" non-determinism in native_cctools build
By omitting the otool binary which is built non-deterministically.
We don't use it anyway.
2019-11-19 19:32:50 +03:00
Howard Chu 0a825e0a3e
Fixup compiled python in OSX 2019-11-19 19:32:10 +03:00
Howard Chu 1c05789afc
Fix unwind library ordering
Sort objects being archived
2019-11-19 19:31:55 +03:00
Howard Chu eee0e5e92f
Fixup sodium darwin
get rid of sodium-darwin.mk special case, unify back with sodium.mk
2019-11-19 19:31:38 +03:00
Howard Chu dff7e526a6
Use standard time for depends caches
streamline, remove obsolete wrappers
2019-11-19 19:31:23 +03:00
Howard Chu 6fbb9cfa4f
Add ARFLAGS
Needed to invoke deterministic mode on some archivers
2019-11-19 19:31:06 +03:00
Howard Chu 7681f4c364
gitian: add FreeBSD 2019-11-19 19:30:25 +03:00
Howard Chu 74e6c5d2fe
depends: Add FreeBSD support 2019-11-19 19:29:59 +03:00
Howard Chu a01ad8b296
gitian: Parametrize target platforms 2019-11-19 19:29:41 +03:00
Howard Chu c236474c4b
gitian: Update to latest gitian-builder 2019-11-19 19:29:28 +03:00
moneromooo-monero bb93513a7c
epee: close connection when the peer has done so
This fixes rapid reconnections failing as the peer hasn't yet
worked out the other side is gone, and will reject "duplicate"
connections until a timeout.
2019-11-19 19:26:49 +03:00
wowario 34940d2e14 initial commit 2019-11-08 16:45:00 +03:00
Riccardo Spagni a48ef0a65a
Merge pull request #6088
e8c5ab515 gitian: fix out dir location (iDunk5400)
2019-11-04 06:14:05 -08:00
iDunk5400 e8c5ab5155
gitian: fix out dir location 2019-11-04 10:25:54 +01:00
Howard Chu 5b78c27c50
Copy LICENSE to all archives 2019-11-04 05:05:38 +00:00
selsta 2bfd41b29c
depends: fix typo in packages 2019-11-04 00:08:00 +01:00
Riccardo Spagni 06b0441762
Merge pull request #6074
38f691048 simplewallet: plug a timing leak (moneromooo-monero)
dcff02e4c epee: allow a random component in once_a_time timeouts (moneromooo-monero)
e10833024 wallet: reuse cached height when set after refresh (moneromooo-monero)
5956beaa1 wallet2: fix is_synced checking target height, not height (moneromooo-monero)
fd35e2304 wallet: fix another facet of "did I get some monero" information leak (moneromooo-monero)
d5472bd87 wallet2: do not send an unnecessary last getblocks.bin call on refresh (moneromooo-monero)
97ae7bb5c wallet2: do not repeatedly ask for pool txes sent to us (moneromooo-monero)
2019-11-03 14:52:16 -08:00
Riccardo Spagni f6201081fa
Merge pull request #6077
240dbb124 gitian: add --rebuild option (Howard Chu)
643860776 Add Android support (Howard Chu)
2019-11-03 14:51:52 -08:00
Howard Chu 240dbb1243
gitian: add --rebuild option
Avoids delays when sourceforge is slow to respond; allows rebuilding
when disconnected from networks.
2019-11-03 21:14:45 +00:00
Howard Chu 643860776e
Add Android support 2019-11-03 21:14:45 +00:00
Howard Chu 436e4c3363
Fix readline build
Make sure it links to our libtinfo from our ncurses build.
Hardcode some basic terminal descriptions into our libtinfo.
Re-enable $HOME/.terminfo support to allow user customization.
Use unlikely terminfo-dir, to prevent accidentally using
differently-configured system databases.
2019-11-03 19:03:31 +00:00
Riccardo Spagni 4ad0f00385
Merge pull request #6079
e4d1674e8 0.15.0.0 release engineering (Riccardo Spagni)
2019-11-02 17:32:39 +02:00
Riccardo Spagni e4d1674e8c
0.15.0.0 release engineering 2019-11-02 17:21:52 +02:00
moneromooo-monero dcff02e4c3
epee: allow a random component in once_a_time timeouts 2019-11-01 20:57:24 +00:00
Riccardo Spagni 78e59f531e
Merge pull request #6059
45b6b6038 Updating gitian yml files for v0.15 (Jonathan Cross)
2019-11-01 16:59:20 +02:00
Jonathan Cross 45b6b60385
Updating gitian yml files for v0.15 2019-10-31 17:36:47 +01:00
luigi1111 bae49e9fbd
Merge pull request #6022
dd28383 depends: bump cppzmq version to 4.4.1 (anonimal)
157b3fc depends: bump zeromq version to 4.1.7 (anonimal)
2019-10-25 13:54:15 -05:00
luigi1111 960c215801
Merge pull request #5357
b3a9a4d add a quick early out to get_blocks.bin when up to date (moneromooo-monero)
2899379 daemon, wallet: new pay for RPC use system (moneromooo-monero)
ffa4602 simplewallet: add public_nodes command (moneromooo-monero)
2019-10-25 13:38:21 -05:00
moneromooo-monero 2899379791
daemon, wallet: new pay for RPC use system
Daemons intended for public use can be set up to require payment
in the form of hashes in exchange for RPC service. This enables
public daemons to receive payment for their work over a large
number of calls. This system behaves similarly to a pool, so
payment takes the form of valid blocks every so often, yielding
a large one off payment, rather than constant micropayments.

This system can also be used by third parties as a "paywall"
layer, where users of a service can pay for use by mining Monero
to the service provider's address. An example of this for web
site access is Primo, a Monero mining based website "paywall":
https://github.com/selene-kovri/primo

This has some advantages:
 - incentive to run a node providing RPC services, thereby promoting the availability of third party nodes for those who can't run their own
 - incentive to run your own node instead of using a third party's, thereby promoting decentralization
 - decentralized: payment is done between a client and server, with no third party needed
 - private: since the system is "pay as you go", you don't need to identify yourself to claim a long lived balance
 - no payment occurs on the blockchain, so there is no extra transactional load
 - one may mine with a beefy server, and use those credits from a phone, by reusing the client ID (at the cost of some privacy)
 - no barrier to entry: anyone may run a RPC node, and your expected revenue depends on how much work you do
 - Sybil resistant: if you run 1000 idle RPC nodes, you don't magically get more revenue
 - no large credit balance maintained on servers, so they have no incentive to exit scam
 - you can use any/many node(s), since there's little cost in switching servers
 - market based prices: competition between servers to lower costs
 - incentive for a distributed third party node system: if some public nodes are overused/slow, traffic can move to others
 - increases network security
 - helps counteract mining pools' share of the network hash rate
 - zero incentive for a payer to "double spend" since a reorg does not give any money back to the miner

And some disadvantages:
 - low power clients will have difficulty mining (but one can optionally mine in advance and/or with a faster machine)
 - payment is "random", so a server might go a long time without a block before getting one
 - a public node's overall expected payment may be small

Public nodes are expected to compete to find a suitable level for
cost of service.

The daemon can be set up this way to require payment for RPC services:

  monerod --rpc-payment-address 4xxxxxx \
    --rpc-payment-credits 250 --rpc-payment-difficulty 1000

These values are an example only.

The --rpc-payment-difficulty switch selects how hard each "share" should
be, similar to a mining pool. The higher the difficulty, the fewer
shares a client will find.
The --rpc-payment-credits switch selects how many credits are awarded
for each share a client finds.
Considering both options, clients will be awarded credits/difficulty
credits for every hash they calculate. For example, in the command line
above, 0.25 credits per hash. A client mining at 100 H/s will therefore
get an average of 25 credits per second.
For reference, in the current implementation, a credit is enough to
sync 20 blocks, so a 100 H/s client that's just starting to use Monero
and uses this daemon will be able to sync 500 blocks per second.

The wallet can be set to automatically mine if connected to a daemon
which requires payment for RPC usage. It will try to keep a balance
of 50000 credits, stopping mining when it's at this level, and starting
again as credits are spent. With the example above, a new client will
mine this much credits in about half an hour, and this target is enough
to sync 500000 blocks (currently about a third of the monero blockchain).

There are three new settings in the wallet:

 - credits-target: this is the amount of credits a wallet will try to
reach before stopping mining. The default of 0 means 50000 credits.

 - auto-mine-for-rpc-payment-threshold: this controls the minimum
credit rate which the wallet considers worth mining for. If the
daemon credits less than this ratio, the wallet will consider mining
to be not worth it. In the example above, the rate is 0.25

 - persistent-rpc-client-id: if set, this allows the wallet to reuse
a client id across runs. This means a public node can tell a wallet
that's connecting is the same as one that connected previously, but
allows a wallet to keep their credit balance from one run to the
other. Since the wallet only mines to keep a small credit balance,
this is not normally worth doing. However, someone may want to mine
on a fast server, and use that credit balance on a low power device
such as a phone. If left unset, a new client ID is generated at
each wallet start, for privacy reasons.

To mine and use a credit balance on two different devices, you can
use the --rpc-client-secret-key switch. A wallet's client secret key
can be found using the new rpc_payments command in the wallet.
Note: anyone knowing your RPC client secret key is able to use your
credit balance.

The wallet has a few new commands too:

 - start_mining_for_rpc: start mining to acquire more credits,
regardless of the auto mining settings
 - stop_mining_for_rpc: stop mining to acquire more credits
 - rpc_payments: display information about current credits with
the currently selected daemon

The node has an extra command:

 - rpc_payments: display information about clients and their
balances

The node will forget about any balance for clients which have
been inactive for 6 months. Balances carry over on node restart.
2019-10-25 09:34:38 +00:00
anonimal 157b3fcff4
depends: bump zeromq version to 4.1.7
Resolves https://hackerone.com/reports/652911
2019-10-25 01:22:17 +00:00
anonimal dd28383a4b
depends: bump cppzmq version to 4.4.1 2019-10-25 00:47:33 +00:00
luigi1111 42d84ad35e
Merge pull request #6006
9f3be3b epee: use SO_REUSEADDR on non-Windows targets (xiphon)
2019-10-24 12:41:59 -05:00
xiphon 9f3be3baed epee: use SO_REUSEADDR on non-Windows targets 2019-10-22 18:40:01 +00:00
luigi1111 6b58d6248a
Merge pull request #5996
23ba69e epee: fix SSL server handshake, run_one() can block, use poll_one() (xiphon)
2019-10-22 10:26:31 -05:00
luigi1111 18f62f89d8
Merge pull request #5986
1080136 abstract_tcp_server2: move 'Trying to connect' from error to debug (moneromooo-monero)
2019-10-22 10:23:04 -05:00
luigi1111 84ce43a239
Merge pull request #5966
be82c40 Support median block size > 4 GB (moneromooo-monero)
2019-10-22 10:08:32 -05:00
moneromooo-monero be82c40703
Support median block size > 4 GB
add a 128/64 division routine so we can use a > 32 bit median block
size in calculations
2019-10-21 10:41:07 +00:00
xiphon 23ba69ec88 epee: fix SSL server handshake, run_one() can block, use poll_one() 2019-10-18 18:32:33 +00:00
luigi1111 7ec8d9640e
Merge pull request #5911
e48dcb7 levin: armour against some 'should not happen' case (moneromooo-monero)
2019-10-16 13:35:55 -05:00
moneromooo-monero e48dcb7a01
levin: armour against some "should not happen" case
If adding a response handler after the protocol is released,
they could never be cancelled again, and would end up keeping
a ref that never goes away
2019-10-15 10:30:08 +00:00
luigi1111 8fcdf77d7b
Merge pull request #5947
c9cfbf7 epee: tcp server - set SO_LINGER instead of SO_REUSEADDR option (xiphon)
2019-10-14 20:04:02 -05:00
luigi1111 4118e4b1e9
Merge pull request #5937
4b654f6 abstract_tcp_server2: log pointer, not contents, where appropriate (moneromooo-monero)
2019-10-14 18:08:47 -05:00
moneromooo-monero 10801362f4
abstract_tcp_server2: move "Trying to connect" from error to debug
and fix the message grammar
2019-10-14 14:15:21 +00:00
luigi1111 da7a3dd17b
Merge pull request #5936
24473d7 build: fix MinGW GUI dependencies build (xiphon)
2019-10-08 14:46:09 -05:00
luigi1111 18da0fa240
Merge pull request #5918
4371791 epee: implement handshake timeout for SSL connections (xiphon)
2019-10-08 14:30:45 -05:00
luigi1111 ca975bcb79
Merge pull request #5917
7d81850 epee: fix network timeouts in blocked_mode_client (xiphon)
2019-10-08 14:28:50 -05:00
xiphon c9cfbf7fb3 epee: tcp server - set SO_LINGER instead of SO_REUSEADDR option 2019-10-02 19:08:02 +00:00