0

I'm currently in chapter 14.1 (verify your tor setup) of the learning bitcoin from the command line course by blockchaincommons.

I don't get my head around doing the actual RPC verification via torify and I assume my linode-node is not running properly behind tor. When I type sudo -u debian-tor tor --verify-config everything is fine and I see the expected result.

However when I try to check the rpc ports in /etc/tor/torrc I can NOT see the hidden service ports described in the docs. There it only says:

############### This section is just for location-hidden services ###

## Once you have configured a hidden service, you can look at the
## contents of the file ".../hidden_service/hostname" for the address
## to tell people.
##
## HiddenServicePort x y:z says to redirect requests on port x to the
## address y:z.

#HiddenServiceDir /var/lib/tor/hidden_service/
#HiddenServicePort 80 127.0.0.1:80

#HiddenServiceDir /var/lib/tor/other_hidden_service/
#HiddenServicePort 80 127.0.0.1:80
#HiddenServicePort 22 127.0.0.1:22

I can see them in the bitcoin.conf file but that doesn't help much... I have an QR-code but I'm not able to connect with my node through it. And I don't have a /var/lib/tor/standup/hostname directory at all.

What I CAN do is verifying my tor-setup for bitcoind running grep "tor:" ~/.bitcoin/testnet3/debug.log.

I assume, something went wrong during the initial install. But can anybody tell me, how to fix it?

PS: Explanations for differences between RPC and bitcoind are also welcome, I think I'm not getting that right either...

5
  • At the top of the guide you linked, it mentions setup with Bitcoin StandUp. I can see that the Linux StandUp script should have set the ports in torrc. Did you use this script? Dec 12, 2021 at 3:56
  • Might checkout the tor guide in bitcoin-core. If your using "option 2" then core is making the Tor service for you via the Tor API.
    – Dan
    Dec 12, 2021 at 6:44
  • @meshcollider yes I did us Bitcoin StandUp. Question is, can I simply add them manually in the displayed section above?
    – zerotobtc
    Dec 12, 2021 at 8:33
  • @zerotobtc I think the setup is more complicated than just adding those lines to the file. I'd recommend using the Tor setup guide linked by Dan Dec 12, 2021 at 9:01
  • Thanks @Dan for the link to the setup guide, that helped!
    – zerotobtc
    Dec 12, 2021 at 9:19

1 Answer 1

1

I still don't know why the error occurred however I found a workaround.

I added the lines

HiddenServiceDir /var/lib/tor/standup/
HiddenServiceVersion 3
HiddenServicePort 1309 127.0.0.1:18332
HiddenServicePort 1309 127.0.0.1:18443
HiddenServicePort 1309 127.0.0.1:8332

in the /etc/tor/torrc file (according to the tor guide) in the hidden service section. Then I restarted tor with systemctl restart tor. Afterwards the /var/lib/tor/standup/hostname file was created and also the torify command went through just fine!

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.