Proxmark3 community

Research, development and trades concerning the powerful Proxmark3 device.

Remember; sharing is caring. Bring something back to the community.


"Learn the tools of the trade the hard way." +Fravia

You are not logged in.

Announcement

Time changes and with it the technology
Proxmark3 @ discord

Users of this forum, please be aware that information stored on this site is not private.

#1 2017-05-12 08:49:38

iceman
Administrator
Registered: 2013-04-25
Posts: 9,537
Website

Win10 - bash - installing dev-env

Since there is a bash shell (ubuntu based) available native from inside Win10,

You need to:

- enable the developer mode   (control panel/updates/for developers/
- enable Windows Subsystem for Linux (beta)   ( turn windows features on off )
- restart computer
- run "bash" and answer yes to some questions,  (and select a username)

Now you have a bash shell to play with.

I had git installed already,  not sure if it comes with bash aswell,   just follow the normal instructions.
git clone proxmark3 repo
sudo apt-install...
and you can compile just fine. smile

However running the proxmark client turned out that Serial ports is lacking support for the bash shell.
sad  so I can't run it.   Will be interesting to see how/when serial ports will be supported. 

Ultimately, this might solve the issue of running proxspace/mingw on windows.

Offline

#2 2017-05-12 09:42:00

ntk
Contributor
Registered: 2015-05-24
Posts: 701

Re: Win10 - bash - installing dev-env

Very surprise for window OS, they could not manage to protect their own space and open now a new front so hackers can have their own game... That could be a new play ground for experience users. But could also be a new mine field.

personally I would stay clear of any mix.

If you are window stay window
If you are ubuntu stay ubuntu
If you are mint stay mint
If you are kali stay kali
ooops forget the third dim people ... If you are Mac stay Mac
you mix the environment, when come to issue, you hardly get any support from OP and could be very alone

Last edited by ntk (2017-05-12 09:43:50)

Offline

#3 2017-05-12 10:55:34

iceman
Administrator
Registered: 2013-04-25
Posts: 9,537
Website

Re: Win10 - bash - installing dev-env

This might be a can of worms mixing bash on windows but if it works then it could be a good thing.

Sidenote,
since this is an opensource commnunity and people do this on their free time,  the expectation of support from me seems very strange.
I don't get paid to answer all mails from ppl who are having trouble or ask questions.   Usually I tell them to post on the forum, since thats the purpose of the forum.

Offline

#4 2017-05-12 12:27:55

gator96100
Contributor
From: Austria
Registered: 2016-03-25
Posts: 177

Re: Win10 - bash - installing dev-env

Not all Windows user are using Win10, so this could only replace proxspace on Win10.
Btw: Seems like serial support is already working in the insider builds(I didn't test it)https://msdn.microsoft.com/en-us/comman … uild-16176

Last edited by gator96100 (2017-05-12 12:28:28)

Offline

#5 2017-05-12 13:13:14

iceman
Administrator
Registered: 2013-04-25
Posts: 9,537
Website

Re: Win10 - bash - installing dev-env

nice link,  https://blogs.msdn.microsoft.com/wsl/20 … for-linux/
claims it should work.
I just don't get any /dev/ttyS...  devices with my pm3 connected on com7.

Offline

#6 2017-11-25 16:34:11

gentilkiwi
Contributor
Registered: 2017-10-10
Posts: 27

Re: Win10 - bash - installing dev-env

I confirm: Windows LSM (Ubuntu based) is able to make a perfect proxmark build !

And after running

sudo chmod 666 /dev/ttyS4

(for my COM4 port)

I was able to run proxmark, and even use flasher for bootrom / fullimage \o/
In bonus, if you have a Xming server running, and...

export DISPLAY=:0

...you have a nice full version, with the graph window!

327981lsm.png

Offline

#7 2017-11-25 17:57:27

iceman
Administrator
Registered: 2013-04-25
Posts: 9,537
Website

Re: Win10 - bash - installing dev-env

Nice one!

Ad I noticed that you need to be registered for  "windows insider preview builds" aswell in order to get the serialport working.

Offline

#8 2017-11-25 18:17:01

gentilkiwi
Contributor
Registered: 2017-10-10
Posts: 27

Re: Win10 - bash - installing dev-env

I'm not registered as it.
I think it's related to : 10.0.16299.19 / 1709 version

edit: developer mode isn't needed anymore smile

Last edited by gentilkiwi (2017-11-25 19:40:56)

Offline

#9 2017-11-26 06:36:19

iceman
Administrator
Registered: 2013-04-25
Posts: 9,537
Website

Re: Win10 - bash - installing dev-env

Yes!  I needed to update my computer in order to get the 1709 version.  Now bash runs proxmark3 out-of-the-box  No more mingw.

But a X-system would be fine.  Which ones can I choose between?!?   I can't see any reference in the list for your xming server

sudo apt list | grep x

Xming - X server for windows
https://sourceforge.net/projects/xming/


Adding the display environment variable to the your bash-profile, no need to call it every time.

echo "export DISPLAY=:0.0" >> ~/.bashrc

Offline

#10 2017-11-26 15:45:20

gentilkiwi
Contributor
Registered: 2017-10-10
Posts: 27

Re: Win10 - bash - installing dev-env

Yep Xming server must be installed outside LSM.
But it works smile

Of course, binaries will not work for everyone (they need to have the LSM layer)... but when developing around Proxmark, it will help a lots smile

Last edited by gentilkiwi (2017-11-26 16:16:42)

Offline

#11 2017-11-26 19:30:54

iceman
Administrator
Registered: 2013-04-25
Posts: 9,537
Website

Re: Win10 - bash - installing dev-env

Works very nice,  however I seem to get problem when flashing.  The ttyS* disappeares when entering flashmode.  Any suggestions?

Offline

#12 2017-11-26 20:20:29

gentilkiwi
Contributor
Registered: 2017-10-10
Posts: 27

Re: Win10 - bash - installing dev-env

Got the same issue, but only one time (the first one).
Don't hesitate to alternate sudo flasher / sudo chmod

Offline

#13 2017-11-27 13:29:19

iceman
Administrator
Registered: 2013-04-25
Posts: 9,537
Website

Re: Win10 - bash - installing dev-env

hm. still no go.  However I'm pleased with running client and plot windows just like that.  I don't need to develop in it.

Offline

#14 2018-07-12 22:44:48

gentilkiwi
Contributor
Registered: 2017-10-10
Posts: 27

Re: Win10 - bash - installing dev-env

Long time, but still a succes smile

Dh7nbgcWkAAPXUa.jpg

Offline

#15 2018-12-11 00:40:24

marzipan
Contributor
Registered: 2018-12-10
Posts: 5

Re: Win10 - bash - installing dev-env

Here's how the Windows Subsystem for Linux setup on Windows 10 worked for me.
[My first non-intro post]

Install WSL. Some guides state running bash.exe for the first time automatically installs the rest of the Linux distro. Instead bash now gives a shortcut to the distros in the Microsoft Store (Microsoft store login not required). Or try: Windows Subsystem for Linux Installation Guide for Windows 10. I chose Ubuntu:

Run the installed distro (Ubunto) and perform the usual updates:

sudo apt update && sudo apt upgrade

Install make and the usual Proxmark dependancies (optional, include x11-apps if you like the idea of classic xeyes or xclock on a Windows desktop!):

sudo apt install make p7zip git build-essential libreadline5 libreadline-dev libusb-0.1-4 libusb-dev libqt4-dev perl pkg-config wget libncurses5-dev gcc-arm-none-eabi libpcsclite-dev libsndfile1-dev

Optional, add this to /etc/wsl.conf (create it) to make Windows file permissions sticky if you plan to access files outside of WSL (eg at /mnt/c):

#Enable extra metadata options by default
[automount]
enabled = true
options = "metadata,umask=22,fmask=111"

Install Xming in Windows and tell WSL where to display windows (as per @iceman's post above):

echo "export DISPLAY=:0.0" >> ~/.bashrc

Pull your favourite Proxmark3 repo, or unzip your favourite release and compile as usual:

cd ~/proxmark3
make clean && make all

Find the com port for Proxmark3 in Windows Device Manager and set the port permission in WSL (where n = Windows com port number). Unfortunately this is not persistent (even with the above wsl.conf settings):

sudo chmod 666 /dev/ttySn

Run Xming if you want Proxmark3 graphs (note Xlaunch is not required, the default settings are fine).

Run Proxmark3:

cd ~/proxmark3/client
./proxmark3 /dev/ttySn

smile

I'm very happy with this setup. ProxSpace works well but, together with the Proxmark software, takes 16.8GB of my desktop hard drive. I'm now using a cheap Linx Windows tablet with only 64GB SSD, the Ubuntu folder on this only uses 2.18GB.

Update March 2019: added libpcsclite-dev dependency required by latest official firmware.
Update January 2020: added libsndfile1-dev dependency required by latest RRG/Iceman firmware.

Last edited by marzipan (2019-03-10 13:03:03)

Offline

#16 2020-01-09 11:46:43

zhuminggang
Contributor
Registered: 2017-09-06
Posts: 46

Re: Win10 - bash - installing dev-env

marzipan wrote:

Here's how the Windows Subsystem for Linux setup on Windows 10 worked for me.
[My first non-intro post]

Install WSL. Some guides state running bash.exe for the first time automatically installs the rest of the Linux distro. Instead bash now gives a shortcut to the distros in the Microsoft Store (Microsoft store login not required). Or try: Windows Subsystem for Linux Installation Guide for Windows 10. I chose Ubuntu:

Run the installed distro (Ubunto) and perform the usual updates:

sudo apt update && sudo apt upgrade

Install make and the usual Proxmark dependancies (optional, include x11-apps if you like the idea of classic xeyes or xclock on a Windows desktop!):

sudo apt install make p7zip git build-essential libreadline5 libreadline-dev libusb-0.1-4 libusb-dev libqt4-dev perl pkg-config wget libncurses5-dev gcc-arm-none-eabi libpcsclite-dev libsndfile1-dev

Optional, add this to /etc/wsl.conf (create it) to make Windows file permissions sticky if you plan to access files outside of WSL (eg at /mnt/c):

#Enable extra metadata options by default
[automount]
enabled = true
options = "metadata,umask=22,fmask=111"

Install Xming in Windows and tell WSL where to display windows (as per @iceman's post above):

echo "export DISPLAY=:0.0" >> ~/.bashrc

Pull your favourite Proxmark3 repo, or unzip your favourite release and compile as usual:

cd ~/proxmark3
make clean && make all

Find the com port for Proxmark3 in Windows Device Manager and set the port permission in WSL (where n = Windows com port number). Unfortunately this is not persistent (even with the above wsl.conf settings):

sudo chmod 666 /dev/ttySn

Run Xming if you want Proxmark3 graphs (note Xlaunch is not required, the default settings are fine).

Run Proxmark3:

cd ~/proxmark3/client
./proxmark3 /dev/ttySn

smile

I'm very happy with this setup. ProxSpace works well but, together with the Proxmark software, takes 16.8GB of my desktop hard drive. I'm now using a cheap Linx Windows tablet with only 64GB SSD, the Ubuntu folder on this only uses 2.18GB.

Update March 2019: added libpcsclite-dev dependency required by latest official firmware.
Update January 2020: added libsndfile1-dev dependency required by latest RRG/Iceman firmware.

Well done!

Offline

Board footer

Powered by FluxBB