Bitcoin Forum

Bitcoin => Electrum => Topic started by: Little Mouse on October 13, 2019, 07:41:13 AM



Title: Electrum Server
Post by: Little Mouse on October 13, 2019, 07:41:13 AM
We can use automatically connect to a server or we can manually connect to a server from the given list.
I am a little bit confused-
Who own the servers? There are a lot of servers. Is all these from Electrum?

Difference between automatic connection and manual connection?


Title: Re: Electrum Server
Post by: Rath_ on October 13, 2019, 07:45:48 AM
Who own the servers? There are a lot of servers. Is all these from Electrum?

The community. Anyone who is running a full Bitcoin node with txindex set to 1 can run an Electrum server.

Difference between automatic connection and manual connection?

Manual connection mode lets you connect to a specific server which you trust. Some nodes might keep the logs and attempt to track their users. There are still many servers that are trying to take advantage of users who didn't upgrade to the latest version by tricking them into downloading a modified version of Electrum


Title: Re: Electrum Server
Post by: Little Mouse on October 13, 2019, 12:21:27 PM
Manual connection mode lets you connect to a specific server which you trust. Some nodes might keep the logs and attempt to track their users. There are still many servers that are trying to take advantage of users who didn't upgrade to the latest version by tricking them into downloading a modified version of Electrum
How can I be sure which server to trust? Any criteria to select a certain server? Or I must switch from server to server very often so that they can't keep the whole logs.


Title: Re: Electrum Server
Post by: Rath_ on October 13, 2019, 12:26:38 PM
How can I be sure which server to trust? Any criteria to select a certain server? Or I must switch from server to server very often so that they can't keep the whole logs.

There is no list of trusted servers. It would be pointless. Switching between servers from time to time should be enough if you are really paranoid. The server operator can only know your IP address and the list of your addresses.
Check out this thread (https://bitcointalk.org/index.php?topic=5130661.0).


Title: Re: Electrum Server
Post by: ABCbits on October 13, 2019, 05:39:20 PM
Manual connection mode lets you connect to a specific server which you trust. Some nodes might keep the logs and attempt to track their users. There are still many servers that are trying to take advantage of users who didn't upgrade to the latest version by tricking them into downloading a modified version of Electrum
How can I be sure which server to trust? Any criteria to select a certain server? Or I must switch from server to server very often so that they can't keep the whole logs.

If you have serious concern about your privacy, you could :
1. Run your own Electrum Server
2. Use proxy (Tor also possible), Electrum support proxy usage. This option is useless, unless you move to different wallet (which detail only obtained with proxy)


Title: Re: Electrum Server
Post by: pooya87 on October 14, 2019, 05:25:39 AM
How can I be sure which server to trust?

Electrum nodes (aka servers) can not compromise your security. the only communication you are making with these nodes is to get block headers, your transaction history and to broadcast new tx you make. all of which are public information, nothing secret to compromise. the only thing malicious sever could do is to lie about state of a transaction. they could tell you it is either confirmed or unconfirmed (or doesn't exist at all) while it is the other way around.

the only real risk is your privacy but you are already giving it up as soon as you start using an SPV wallet instead of a full verification node.


Title: Re: Electrum Server
Post by: Lucius on October 14, 2019, 12:54:56 PM
Electrum nodes (aka servers) can not compromise your security.

I know it's unlikely, but servers get our real IP (if we don't hide it), and the person who owns the server can determine our location (country) by IP address. Although small, there is a possibility that someone could reach the real owner through an IP address, by hacking ISP or with inside job (a corrupt employee inside ISP). Of course, this would only make sense if some Electrum wallet user has a large amount of BTC, and in this way could become a victim of robbery or attempts of social engineering.



Title: Re: Electrum Server
Post by: naska21 on October 17, 2019, 06:19:12 PM
Electrum nodes (aka servers) can not compromise your security.

I know it's unlikely, but servers get our real IP (if we don't hide it), and the person who owns the server can determine our location (country) by IP address. Although small, there is a possibility that someone could reach the real owner through an IP address, by hacking ISP or with inside job (a corrupt employee inside ISP). Of course, this would only make sense if some Electrum wallet user has a large amount of BTC, and in this way could become a victim of robbery or attempts of social engineering.


If the privacy is your major concern then  you  have an option to run an Electrum personal server and benefit from its use. The only cons of such approach, as I see it, is the necessity to run in background a fully synced  bitcoind. That demon  is naturally going to  consume a lot of  space for blockchain storage which means  you need the disk (preferably SSD) with big capacity, .


Title: Re: Electrum Server
Post by: pooya87 on October 18, 2019, 03:40:56 AM
Electrum nodes (aka servers) can not compromise your security.

I know it's unlikely, but servers get our real IP (if we don't hide it), and the person who owns the server can determine our location (country) by IP address. Although small, there is a possibility that someone could reach the real owner through an IP address, by hacking ISP or with inside job (a corrupt employee inside ISP). Of course, this would only make sense if some Electrum wallet user has a large amount of BTC, and in this way could become a victim of robbery or attempts of social engineering.


If the privacy is your major concern then  you  have an option to run an Electrum personal server and benefit from its use. The only cons of such approach, as I see it, is the necessity to run in background a fully synced  bitcoind. That demon  is naturally going to  consume a lot of  space for blockchain storage which means  you need the disk (preferably SSD) with big capacity, .

if you are concerned with space then you shouldn't be running an Electrum server because it takes up a lot more space than a regular node because it has to index the entire blockchain so that it can fetch the data that anybody requests (transaction history, balances,...). it is a lot easier to run a regular full node and for space you can just run it in pruned mode.


Title: Re: Electrum Server
Post by: Lucius on October 18, 2019, 11:47:54 AM
If the privacy is your major concern then  you  have an option to run an Electrum personal server and benefit from its use.

Everyone should be concerned with privacy when it comes to cryptocurrency, but running a personal server is not something that anyone can do. My questions is just about possibility that any owner of Electrum server can see our IP address and our coins address/es. In today's world where hackers are becoming more and more imaginative, the use of data from such servers can serve them for target selection.

It would be ideal if everyone could have a personal server, or if everyone could use Tor, but most still do not hide their true IP address.


Title: Re: Electrum Server
Post by: mocacinno on October 18, 2019, 11:52:41 AM

--snip--
My questions is just about possibility that any owner of Electrum server can see our IP address and our coins address/es.
--snip--

To answer this question: yes, owners can log ip's and addresses on several levels... It's so easy anybody could do this.
Either by running a reverse proxy (like nginx) in front of the electrum server and logging everything, or by modifying the electrum server's sourcecode to add extra logging (most, if not all, implementations are open source), or just from the OS level by capturing the packages over electrum's port (wireshark can capture the packages and automatically decrypt them using the keyfile used to setup ssl).

If you're really paranoid, i'd suggest using electrs (https://github.com/romanz/electrs/), that way you don't have to add txindex=1 to your node's config and use an alias or shortcut to start electrum using only your own node.

Using tor is a good alternative to, but you have to make sure you always start the tor proxy, and never open electrum without using said proxy...


Title: Re: Electrum Server
Post by: mocacinno on October 18, 2019, 07:57:01 PM
--snip--

I just heard about electrs, by any chance do you have experience running it?

You don't need to enable txindex


Yes, I have installed electrs in the past... It's slower than other implementations, but it was really easy to setup and run on my existing node without having to reindex... Iirc, I used nginx as a reverse proxy to deny incoming connections from non whitelisted ip's and handle ssl encryption.

As for the tor option: I had no idea... I either connect to my own node or to a public electrum server over the clearnet... But than again, I don't hold enough crypto to fear getting robbed...


Title: Re: Electrum Server
Post by: mocacinno on October 19, 2019, 06:55:59 PM
@ETFbitcoin: I've run other electrum servers in the past and electrs feeled less performant... However, I did not run any benchmarks....

As for the fear of getting robbed: there was a discussion in this thread about a node operator logging your real ip and your addresses. If the operator finds an address in his logs that's funded with hundreds of btc, he might try to connect the ip to a physical address (for example by a social engineering attack on the ISP), or he might try to connect to the user's modem to see if it's running vulnerable firmware so the bad node operator can penetrate the rich user's home network... Tor mitigates this attack vector since the operator will not have the user's real ip in his logs


Title: Re: Electrum Server
Post by: HCP on October 31, 2019, 08:01:32 PM
I have been using "electrs" pretty much exclusively for my Electrum for a while now... I actually run it in an Ubuntu container using the "Windows Subsystem for Linux" :P

It runs fine for my single user use-case... not idea what it would be like as a "public" server.


Title: Re: Electrum Server
Post by: Dabs on November 06, 2019, 09:42:25 PM
Yeah, what's a good server for electrum? I see a bunch of different implementations, electrumx, and electrum for personal by belcher i think, and a few others.

There was even this guy running Electrum for private users in this forum, I might just set one up too ... "Dabs Electrum Server that does not log, but you can still use Tor."


Title: Re: Electrum Server
Post by: HCP on November 06, 2019, 11:56:15 PM
I guess it depends on your use case... if you just want it for personal use, then like I said, electrs works well, but I've no idea how it would handle being a "public" (or whitelist) server with multiple concurrent connections.

I looked at the other implementations, but from memory they would require me to resync Bitcoin Core from scratch.


Title: Re: Electrum Server
Post by: alomar on November 21, 2019, 04:18:20 PM
Electrum nodes (aka servers) can not compromise your security.

I know it's unlikely, but servers get our real IP (if we don't hide it), and the person who owns the server can determine our location (country) by IP address. Although small, there is a possibility that someone could reach the real owner through an IP address, by hacking ISP or with inside job (a corrupt employee inside ISP). Of course, this would only make sense if some Electrum wallet user has a large amount of BTC, and in this way could become a victim of robbery or attempts of social engineering.


If the privacy is your major concern then  you  have an option to run an Electrum personal server and benefit from its use. The only cons of such approach, as I see it, is the necessity to run in background a fully synced  bitcoind. That demon  is naturally going to  consume a lot of  space for blockchain storage which means  you need the disk (preferably SSD) with big capacity, .

this need to run a full Bitcoin node makes no sense to me.  the whole purpose of an lightweight client like Electrum was to avoid this.

would running Electrum behind a VPN be sufficient to obscure my IP address?


Title: Re: Electrum Server
Post by: TryNinja on November 21, 2019, 04:30:59 PM
would running Electrum behind a VPN be sufficient to obscure my IP address?
Yes, but only your IP. The server stills gets a list of your addresses (which could be bad for privacy).

Electrum is a convenience that obviously costs a bit of privacy. If you want full privacy, then running a full node is probably the answer.


Title: Re: Electrum Server
Post by: alomar on November 21, 2019, 04:36:50 PM
would running Electrum behind a VPN be sufficient to obscure my IP address?
Yes, but only your IP. The server stills gets a list of your addresses (which could be bad for privacy).

Electrum is a convenience that obviously costs a bit of privacy. If you want full privacy, then running a full node is probably the answer.

how does the Electrum node aggregate your addresses to your particular wallet?  is it b/c your specific request for your addy's are bundled or linked to a specific session?


Title: Re: Electrum Server
Post by: TryNinja on November 21, 2019, 04:39:11 PM
how does the Electrum node aggregate your addresses to your particular wallet?  is it b/c your specific request for your addy's are bundled or linked to a specific session?
AFAIK your wallet sends the addresses it wants to know the balance/transaction to the node (server), the node figures out this info and sends the balance and transactions data back to you. Your wallet (client) is the one that initially knows the addresses, which are originated from the wallet seed.

Was that your question? (I may have misinterpreted it).


Title: Re: Electrum Server
Post by: alomar on November 21, 2019, 04:56:44 PM
how does the Electrum node aggregate your addresses to your particular wallet?  is it b/c your specific request for your addy's are bundled or linked to a specific session?
AFAIK your wallet sends the addresses it wants to know the balance/transaction to the node (server), the node figures out this info and sends the balance and transactions data back to you. Your wallet (client) is the one that initially knows the addresses, which are originated from the wallet seed.

Was that your question? (I may have misinterpreted it).

i guess it was a stupid question.  you send it a list of addy's you want from your specific IP (hidden or not) and then the server gathers them up and has to send the info back to your IP.  thus, you wallet addy's are aggregated with total balance known.  >:(

i still don't get the idea of running a personal Electrum server when you have to run a full node right beside it.  is it b/c of the enhanced functionality?  with Andrew Chow's HWI, my guess that Electrum's advantages are becoming much less of a distinction now?


Title: Re: Electrum Server
Post by: HCP on November 21, 2019, 07:48:35 PM
If you're just trying to obscure your IP... your options are TOR (or some other VPN). Although, running via VPNs has been the cause of issues for folks in the past. Mostly the inability to connect to servers and/or sync.

More info here: https://electrum.readthedocs.io/en/latest/tor.html


Title: Re: Electrum Server
Post by: Dabs on November 21, 2019, 10:07:26 PM
Electrum, the wallet itself, is a light client. Just like the Bitcoin Wallet for Android is a light client.

Those things need to connect to either other full nodes, or servers (which are in turn hosting full nodes.) The Bitcoin Wallet is SPV so it connects directly to other full nodes, and you can specify it only connects to one node (maybe your full node that runs at home).

Electrum tries to connect to several different Electrum servers, so it's possible it can get your wallet balance of different addresses from different servers who won't know all the same addresses.

But running your own Electrum server is the only know to know for sure that you don't leak out any of that address info because you're running a full node.

You could run the full node on a separate server, and Electrum wallet client runs at your own computer or on your mobile device.

I happen to have a server and workstation at home, so I just simply run a full node. Eventually I might run my own personal Electrum server just for myself. (Or as another use did, make it a semi-private server and offer to whitelist your ip address so you can connect your Electrum wallet to my Electrum server.; but then you'd have to trust that I'm too lazy to record anything and not keep records.)

As for IP address:

You could do one step further and rent a VPS, install Electrum on it, then remote to it, but then you'd have to trust the VPS provider. Maybe just get a VPS and run a personal VPN on it.


Title: Re: Electrum Server
Post by: naska21 on November 22, 2019, 09:44:00 AM
snip

As for IP address:

You could do one step further and rent a VPS, install Electrum on it, then remote to it, but then you'd have to trust the VPS provider. Maybe just get a VPS and run a personal VPN on it.

From where I sit, other option is to run Tails OS that has Electrum client  as one of its apps and communicate with server via TOR network.


Title: Re: Electrum Server
Post by: alomar on November 22, 2019, 05:37:33 PM
If you're just trying to obscure your IP... your options are TOR (or some other VPN). Although, running via VPNs has been the cause of issues for folks in the past. Mostly the inability to connect to servers and/or sync.

More info here: https://electrum.readthedocs.io/en/latest/tor.html

i just read your link and it says this, which is confusing in the sense that this entire discussion is premised on the idea that Electrum is connecting to ONE potentially malicious server.  which is it?:

This is because normally Electrum connects to a few different servers and downloads block headers and checks that they match. This prevents / makes it more difficult for Rogue servers to send you bad information.


edit:  seems to me one should avoid setting the network server to a specific Electrum node but instead leave it on automatic to hopefully connect to multiple servers for your addy balances (assuming you aren't going to use a personal server or want to use a VPN instead).


Title: Re: Electrum Server
Post by: HCP on November 26, 2019, 11:57:01 PM
edit:  seems to me one should avoid setting the network server to a specific Electrum node but instead leave it on automatic to hopefully connect to multiple servers for your addy balances (assuming you aren't going to use a personal server or want to use a VPN instead).
Correct... generally the best course of action would be to leave it on "Auto"... and simply use a VPN to hide your IP if that is your sole concern (and you're not wanting to run a personal server etc).


Title: Re: Electrum Server
Post by: alomar on November 27, 2019, 01:07:09 AM
edit:  seems to me one should avoid setting the network server to a specific Electrum node but instead leave it on automatic to hopefully connect to multiple servers for your addy balances (assuming you aren't going to use a personal server or want to use a VPN instead).
Correct... generally the best course of action would be to leave it on "Auto"... and simply use a VPN to hide your IP if that is your sole concern (and you're not wanting to run a personal server etc).

so do we know how many servers Electrum pulls balances from in Auto mode?  will it sometimes just pull from one?

can one run an ElectrumX server with Bitcoin Core in prune mode?


Title: Re: Electrum Server
Post by: TryNinja on November 27, 2019, 01:25:42 AM
so do we know how many servers Electrum pulls balances from in Auto mode?  will it sometimes just pull from one?
I may be wrong, but I always though you only connected to a single server at once? Like, you can use multiple servers in a short period of time (e.g every time you restart Electrum it can choose a different server), but since in the server list window it only shows a single connected server and there isn't even space for a multi listing, I believe you don't connect to multiple servers at once.


Title: Re: Electrum Server
Post by: alomar on November 27, 2019, 01:34:32 AM
so do we know how many servers Electrum pulls balances from in Auto mode?  will it sometimes just pull from one?
I may be wrong, but I always though you only connected to a single server at once? Like, you can use multiple servers in a short period of time (e.g every time you restart Electrum it can choose a different server), but since in the server list window it only shows a single connected server and there isn't even space for a multi listing, I believe you don't connect to multiple servers at once.

ok, so this is interesting.  i decided to look:

https://i.postimg.cc/zvfgRXGh/Screenshot-from-2019-11-26-17-32-08.png (https://postimages.org/)

https://i.postimg.cc/cJMg98KY/Screenshot-from-2019-11-26-17-32-23.png (https://postimages.org/)

i'm connected to 7 different nodes at once.  did i get my addy balances from all 7 and in what proportion?  or did i just get them from electrum2.hodlister.co?


Title: Re: Electrum Server
Post by: HCP on November 27, 2019, 03:07:38 AM
i'm connected to 7 different nodes at once.  did i get my addy balances from all 7 and in what proportion?  or did i just get them from electrum2.hodlister.co?
All your requests (ie. address balance history, sending transactions etc)... go through whatever is listed in "Server"... so, in your screenshot above "electrum2.hodlister.co" (also highlighted with a * in the node list).

The "nodes" you are connected to provide Blockheader information and help determine what Electrum considers to be the "longest chain" etc


can one run an ElectrumX server with Bitcoin Core in prune mode?
Short answer... NO.

Longer Answer:
You must to be running a non-pruning bitcoin daemon with:
Code:
txindex=1
set in its configuration file. If you have an existing installation of bitcoind and have not previously set this you will need to reindex the blockchain with:

Code:
bitcoind -reindex
which can take some time.


Also... try clicking the "?" buttons in Electrum... The "Status" one shows this:
https://talkimg.com/images/2023/11/15/z45DT.png

The "Server" one shows this:
https://talkimg.com/images/2023/11/15/z49Zl.png


Title: Re: Electrum Server
Post by: pooya87 on November 27, 2019, 05:55:44 AM
i still don't get the idea of running a personal Electrum server when you have to run a full node right beside it.  is it b/c of the enhanced functionality? 

it depends on how you are setting up and using that "electrum server". for example if it is on the same computer then you are right, there is no point. but usually people run it on another computer or an actual "server" like Amazon VPS, it is online 24/7 that way and you just connect to that IP address. or maybe you have multiple wallets (on desktop at home, desktop at work, phone, laptop,...) and connect all of them to that one server you yourself run. that way you have control and functionality and can keep your privacy.


Title: Re: Electrum Server
Post by: Dabs on November 29, 2019, 05:10:15 PM
There is also that Personal Electrum Server, and it can run a pruned bitcoin node. It's specific to your wallet or seed or address or something like that.