Tutorial  Updated

Building a Switch-lan-play client on your android phone

Note: this post is out of date and will not be updated. Please use this tutorial instead!
https://gbatemp.net/threads/zero-to-smashing-local-wireless-online-ldn_mitm-guide.526228/



Noticed a lot of people asking for this bit there isn't much help with this... so here it is....

Note:
no credit for this as I didn't make any of this.
All credit goes to the dev for the programs used. Also I wrote this up on my phone... Excuse me for the formatting. Will fix it up when I get the chance to.

Disclaimer: some phones are different and if this doesn't work, post here and we'll see if we can find a way around this. Also if your phone over heat, blows up, turns into an apple, and other issue or problem other you may encounter, none of those are my fault and you agree to the risk following or reading this tut


Requirements
Procedures
1. First you need to download the libs and packages required to build the client. Launch termux and enter in the following
Code:
apt update
apt install libpcap-dev
apt install libuv-dev
pkg install cmake
pkg install tsu
pkg install git

2. Download the git
Code:
git clone https://github.com/spacemeowx2/switch-lan-play.git

3. Change directory into the git folder and make a build directory
Code:
cd switch-lan-play
mkdir build
cd build

4. Build your client now
Code:
cmake ..
make

5.Your client is now built, to run it you use
Code:
tsudo ./lan-play --relay-server-addr example.com:11451

6. Profit

Links:
How to set up your switch: http//www.lan-play.com/install

Space's GitHub: https://github.com/spacemeowx2/switch-lan-play

Space's android script: https://gist.github.com/spacemeowx2/b2f336489ce621c9d177db0fb35940f1
 
Last edited by lil-devil,

MisterMue

Active Member
Newcomer
Joined
Jan 18, 2013
Messages
43
Trophies
0
XP
577
Country
Germany
i read your post about infos and do not want to follow links to get the puzzle solved. See it as a service to the reader who is not informed about each detail.
 

lil-devil

Well-Known Member
OP
Member
Joined
Oct 16, 2007
Messages
225
Trophies
0
Age
33
Website
Visit site
XP
906
Country
Canada
i read your post about infos and do not want to follow links to get the puzzle solved. See it as a service to the reader who is not informed about each detail.
Sorry I forget there are plenty of lazy people that requires to be spoon fed... Enjoy
Make you and your friends play games like in a LAN
 
  • Like
Reactions: Berry112

gothteen

Active Member
Newcomer
Joined
Jan 13, 2011
Messages
34
Trophies
1
XP
328
Country
Netherlands
Just a quick question: since this is based on linux (or a fork), is it possible to port it over to a rasp-pi 3 or something? Would be great to have this app running localy but not on any phone or pc, just a dedicated micro pc should do the trick (but thats just assumption)
 

annson24

The Patient One
Member
Joined
May 5, 2016
Messages
1,191
Trophies
0
Age
32
XP
1,843
Country
Philippines
I'm having a

/system/bin/sh: ./lan-play: not found

Error.

I'm on galaxy s8 rooted with magisk.

Sent from my SM-G950F using Tapatalk
 

DeadlySin9

Member
Newcomer
Joined
Aug 21, 2015
Messages
16
Trophies
0
Age
26
XP
109
Country
United States
Anyone tried running this on something like UserLAnd for non rooted users? Planning to try later if nobody has.

EDIT: Seems to run into a permissions issue: "Error pcap_findalldevs: socket: Permission denied"
Running as the root user in the machine doesn't seem to fix it, so device root may be necessary.
 
Last edited by DeadlySin9,

annson24

The Patient One
Member
Joined
May 5, 2016
Messages
1,191
Trophies
0
Age
32
XP
1,843
Country
Philippines
I'm having a

/system/bin/sh: ./lan-play: not found

Error.

I'm on galaxy s8 rooted with magisk.

Sent from my SM-G950F using Tapatalk
I think I found out why I'm having the 'not found' problem. But I don't know how to fix it.
3aa4d1ca077848d433f5d275d3c89eab.jpg


Sent from my SM-G950F using Tapatalk
 

lil-devil

Well-Known Member
OP
Member
Joined
Oct 16, 2007
Messages
225
Trophies
0
Age
33
Website
Visit site
XP
906
Country
Canada
Awesome!

I will add that to the OP
Only thing i notice is, i find most phones i use doesn't come with cmake, so might be a good idea to install cmake on yours.
but then again, users can figure that out them self i guess....

Anyone tried running this on something like UserLAnd for non rooted users? Planning to try later if nobody has.

EDIT: Seems to run into a permissions issue: "Error pcap_findalldevs: socket: Permission denied"
Running as the root user in the machine doesn't seem to fix it, so device root may be necessary.
No, in order for this to work, libpcap must have root access to view the network interface and modify it, hence root is required (just like on windows you may have to do a run as admin)

I think I found out why I'm having the 'not found' problem. But I don't know how to fix it.
3aa4d1ca077848d433f5d275d3c89eab.jpg


Sent from my SM-G950F using Tapatalk
Do an
Code:
ls
what does that show?
you have to make sure you're in the "switch-lan-play/build" folder to run it.
 

annson24

The Patient One
Member
Joined
May 5, 2016
Messages
1,191
Trophies
0
Age
32
XP
1,843
Country
Philippines
Awesome!

I will add that to the OP
Only thing i notice is, i find most phones i use doesn't come with cmake, so might be a good idea to install cmake on yours.
but then again, users can figure that out them self i guess....


No, in order for this to work, libpcap must have root access to view the network interface and modify it, hence root is required (just like on windows you may have to do a run as admin)


Do an
Code:
ls
what does that show?
you have to make sure you're in the "switch-lan-play/build" folder to run it.
Sorry for the late response. Gbatemp was having a maintenance when I sent the reply, anyway, here it is again.

f4c2846e9cf98179f15df9a5041e383a.jpg

Sent from my SM-G950F using Tapatalk
 

gothteen

Active Member
Newcomer
Joined
Jan 13, 2011
Messages
34
Trophies
1
XP
328
Country
Netherlands
Nvm about the rasp, got it running localy on it (and it runs perfectly).
Just had a minor adjustment to some of the commands (Sudo instead of tsudo for instance), installed cmake and made the program within seconds.

pi.png


Now to make it go autopilot if i turn off/on the raspberry pi... oh well, at least it runs :)
 
Last edited by gothteen,

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
  • No one is chatting at the moment.
  • Quincy @ Quincy:
    Usually when such a big title leaks the Temp will be the first to report about it (going off of historical reports here, Pokemon SV being the latest one I can recall seeing pop up here)
  • K3Nv2 @ K3Nv2:
    I still like how a freaking mp3 file hacks webos all that security defeated by text yet again
  • BigOnYa @ BigOnYa:
    They have simulators for everything nowdays, cray cray. How about a sim that shows you playing the Switch.
  • K3Nv2 @ K3Nv2:
    That's called yuzu
    +1
  • BigOnYa @ BigOnYa:
    I want a 120hz 4k tv but crazy how more expensive the 120hz over the 60hz are. Or even more crazy is the price of 8k's.
  • K3Nv2 @ K3Nv2:
    No real point since movies are 30fps
  • BigOnYa @ BigOnYa:
    Not a big movie buff, more of a gamer tbh. And Series X is 120hz 8k ready, but yea only 120hz 4k games out right now, but thinking of in the future.
  • K3Nv2 @ K3Nv2:
    Mostly why you never see TV manufacturers going post 60hz
  • BigOnYa @ BigOnYa:
    I only watch tv when i goto bed, it puts me to sleep, and I have a nas drive filled w my fav shows so i can watch them in order, commercial free. I usually watch Married w Children, or South Park
  • K3Nv2 @ K3Nv2:
    Stremio ruined my need for nas
  • BigOnYa @ BigOnYa:
    I stream from Nas to firestick, one on every tv, and use Kodi. I'm happy w it, plays everything. (I pirate/torrent shows/movies on pc, and put on nas)
  • K3Nv2 @ K3Nv2:
    Kodi repost are still pretty popular
  • BigOnYa @ BigOnYa:
    What the hell is Kodi reposts? what do you mean, or "Wut?" -xdqwerty
  • K3Nv2 @ K3Nv2:
    Google them basically web crawlers to movie sites
  • BigOnYa @ BigOnYa:
    oh you mean the 3rd party apps on Kodi, yea i know what you mean, yea there are still a few cool ones, in fact watched the new planet of the apes movie other night w wifey thru one, was good pic surprisingly, not a cam
  • BigOnYa @ BigOnYa:
    Damn, only $2.06 and free shipping. Gotta cost more for them to ship than $2.06
    +1
  • BigOnYa @ BigOnYa:
    I got my Dad a firestick for Xmas and showed him those 3rd party sites on Kodi, he loves it, all he watches anymore. He said he has got 3 letters from AT&T already about pirating, but he says f them, let them shut my internet off (He wants out of his AT&T contract anyways)
  • K3Nv2 @ K3Nv2:
    That's where stremio comes to play never got a letter about it
  • BigOnYa @ BigOnYa:
    I just use a VPN, even give him my login and password so can use it also, and he refuses, he's funny.
  • BigOnYa @ BigOnYa:
    I had to find and get him an old style flip phone even without text, cause thats what he wanted. No text, no internet, only phone calls. Old, old school.
  • Psionic Roshambo @ Psionic Roshambo:
    @BigOnYa, Lol I bought a new USB card reader thing on AliExpress last month for I think like 87 cents. Free shipping from China... It arrived it works and honestly I don't understand how it was so cheap.
    Psionic Roshambo @ Psionic Roshambo: @BigOnYa, Lol I bought a new USB card reader thing on AliExpress last month for I think like 87...