1

Before all of this, I wanted to make my raspberry pi a wireless access point so that all traffic is anonymous through tor.

I currently have Raspberry pi 3 b+ and I installed Raspbian freshly. Pi 3 B+ has inbuilt wireless ability that could be used without any external wifi card or dongle.

When I searched through internet, I found this page

After having multiple failed attempts, I researched and started from scratch according to the following answer given by user 'Ingo' to the question

I went for the bridged connection(given in that answer), for the ability to access internet when logged in to pi. All steps for that was followed as given there skipping some portion not needed.

I was able to make an access point and bridge my ethernet and wifi network. The bridged network was named "br0". Both of ethernet and wireless network were working correctly.

After that only thing remaining was to install and enable tor.

So, because NAT setup was used in hackaday project, I searched and found this site and followed the steps mentioned there

I connected my phone to the wireless access point and went to official tor site to checked if tor was working or not.

tor not working

Then, as I researched for it I could only found methods including other scripts like hostpad, or some repository. But I intended to have the setup solely using in built linux operations and only wanted to externally install and set up tor.

I just halted there. I wanted to set up raspberry pi as WAP using the above(as I did) and set up tor for traffic. I am willing to do it from scratch. I just need some reference of whole process or some other error free way.

How can it be done?

K_lash96
  • 41
  • 6

1 Answers1

1

You have to make the RasPi a Tor Proxy that will redirect all data to the Tor network. The good news is that the setup of a Tor proxy does not depend on the underlying network configuration. So you can use any stable network configuration to setup a Tor proxy on it.

Because you have already Setting up a Raspberry Pi as an access point - the easy way that's a good entry point for my suggestion. It doesn't fit exactly your needs because the example uses a WiFi repeater with a wireless uplink. But it should not be a big issue to adapt it to your needs with a wired uplink. You can look at How to make Raspberry Pi a Tor router with all kind of network setup using systemd-networkd.

In that tuturial is an example given to set /usr/local/etc/default/torproxy. Don't use that, instead set it to:

# interface to be used as entry point to the Tor network
TOR_IFNAME=wlan0
TOR_IFADDR=192.168.4.1

You wrote that your bridged access point is running. I assume your access point has the ip address 192.168.4.1. If not then change TOR_IFADDR= to that of your access point. Then go on with setting up the tor proxy.

Ingo
  • 42,107
  • 20
  • 85
  • 197
  • I will do that during a couple of days and get back to you. – K_lash96 Apr 27 '19 at 09:08
  • I did all specified in your first answer in setting up a bridge. You specified in second answer that first one was not meant for a stable setup. Should I do all over again considering to have a secure stable setup? – K_lash96 May 30 '19 at 02:24
  • I searched for some time, but couldn't find useful info to what I want to do and how to understand it. If you could guide me to some referable resource, that would be helpful. No issues by my side if that's not the case. – K_lash96 May 30 '19 at 03:39
  • @K_lash96 I'm just a bit busy. Will come back later. – Ingo May 30 '19 at 09:07
  • okay! I will check back later. – K_lash96 May 31 '19 at 03:33
  • @K_lash96 I have clarified the two answers to Setting up a Raspberry Pi as an access point - the easy way. Just look at the headlines and the beginning of the answers. The answer ━━━ Setting up an access point ━━━ is the right one for a stable setup. – Ingo May 31 '19 at 08:10
  • @K_lash96 I have updated my answer to configure a tor proxy. Please give me feedback. – Ingo Jun 01 '19 at 18:15
  • I am on it. Will come back after doing the suggested steps. Sorry for the delay. – K_lash96 Jun 08 '19 at 00:20
  • But regarding with bridge, routing and NAT, which one is more secure? – K_lash96 Jun 08 '19 at 01:17
  • @K_lash96 Using a bridge or routing or NAT isn't an issue of security. All these networking things are made before the entry point of the Tor proxy. To improve security on network interfaces there is iptables used. – Ingo Jun 08 '19 at 23:24
  • Thanks for the clarification. I will try to follow up your post. – K_lash96 Jun 20 '19 at 01:46
  • I made the bridge successfully and phone is responding to Internet connection through bridge, but I can see no notification or sign/symbol for the wifi(if it is on or off) or ethernet. But it is just a minor issue as connection is running. Now, I have two wpa_supplicant files in /etc/wpa_supplicant one is wpa_supplicant.conf and other is wpa_supplicant-wlan0.conf. I think there should be one as it is controlling the network. Where am I going wrong? – K_lash96 Jun 25 '19 at 00:37