Showing posts with label kali linux. Show all posts
Showing posts with label kali linux. Show all posts

Saturday, 20 December 2014

Distro hunt for Dell M4800

Few weeks ago i received my Dell M4800 Mobile Workstation. It's a nice machine with good config and lot of power.
My config has

Intel Core i7-4710MQ
QHD+ Screen (3200x1800)
16GB RAM
128GB SSD
750 GB 7200 RPM HDD
SmartCard Reader
FingerPrint Reader

However, before placing order with Dell i did a lot of search on google to find reviews of existing owners of M4800.
And i found that lot of users are not happy with M4800 with Linux. Few have WiFi issues, few have screen brightness issues, few have problem with sound and etc...

Even after reading about those problems i decided to go with Linux (as left Windows 3 years ago and now live with Linux for day to day use, now i use Windows only for .Net development only). 

After receiving the machine, first i tried to get my hands dirty with preinstalled Ubuntu 12.04 LTS. It is working fine and there were no such issues as i read over internet.
But Ubuntu 12.04 is quite old and also i don't like Unity. So i decided to try other distro.

I tried with following distros
Ubuntu 14.04
Kubuntu 14.04
Kali Linux  (based on Debian) with Gnome3
Kali Linux with KDE4
Arch Linux with Gnome3
Arch Linus with KDE4

Except the Arch+KDE all distro has some problems. One thing is working in a distro but not in other and vise-versa.

Here is summery of different distro evaluation on M4800.


Ubuntu 12.04 LTS
Kernel 3.5.X
Ubuntu 14.04
Kernel 3.13.X
Kubuntu 14.04
Kernel 3.13.X
Kali Linux + Gnome
Kernel 3.14.X
Kali Linux + KDE
Kernel 3.14.X
Arch + Gnome
Kernel 3.17.X
Arch + KDE
Kernel 3.17.X
Hardware






SoundWorkingWorkingWorkingWorkingWorkingWorkingWorking
WiFiWorkingWorkingWorkingWorkingWorkingWorkingWorking
WiFi Switch on/off
WiFi should auto-connect after switch off and on
WorkingWorkingWorkingWorkingWorkingWorkingWorking
BluetoothWorkingWorkingWorkingWorkingWorking
But doesn't recognize unless once turn radio (hardware wifi switch) off then on.
WorkingWorking
WebcamWorkingWorkingWorkingWorkingWorkingWorkingWorking
Fingerprint Reader(not tested)(not tested)(not tested)(not tested)(not tested)(not tested)(not tested)
Smartcard Reader(not tested)(not tested)(not tested)(not tested)(not tested)(not tested)(not tested)
Keys






BrightnessWorkingNOT WORKINGWorking
But response was slow. After pressing keys it take 1-2 sec to change brightness.
NOT WORKINGWorkingNOT WORKINGWorking
Touchpad ToggleWorkingWorkingWorkingWorkingNOT WORKINGWorkingWorking
SleepWorkingWorkingWorkingWorkingWorkingWorkingWorking
Volume ButtonsWorkingWorkingWorkingWorkingWorkingWorkingWorking
Other






Screen Lock
Password box should appear to unlock (no blank screen)
WorkingWorkingWorkingWorkingWorkingWorkingWorking
Screen Turn Off
Screen should turn on after mouse/keyboard activity
WorkingWorkingWorkingWorkingWorkingWorkingWorking
Wakeup After Sleep
Screen should turn on and Password box should appear wakeup
WorkingWorkingWorkingWorkingWorkingWorkingWorking
Virtual Terminal
Blank Screen Problem
NOT WORKINGNOT WORKINGNOT WORKINGNOT WORKINGNOT WORKINGNOT WORKINGNOT WORKING
OS StabilityGOODUNSTABLEUNSTABLEGOODGOODGOODGOOD
Here Virtual Terminal Blank Screen Problem exist on all distros. It is actually the problem with nVidia display driver and distros has nothing to do with it (i guess).

As you can see above, only two distros are working fine. One is Ubuntu 12.04 LTS that comes preinstalled, and another is Arch Linux with KDE.

After playing with both the distro i prefer Arch. I found Arch very light weight, much responsive than Ubuntu and without bloatware (that Ubuntu has like Unity).

So it is all about the distro hunt for Dell M4800. I spend many days to find a working and stable distro so i thought i should share it, it may help another M4800 owner ;)

Saturday, 31 August 2013

Install NVIDIA Proprietary Driver in Kali Linux and Debian wheezy

If you are using Linux and have NVIDIA graphics card then most likely you are using open source NVIDIA driver nouveau. It works quite well, but if you want to use 3D acceleration feature or want to use GPU based applications then you need to install NVIDIA proprietary driver. Here is how to do it. First Install linux headers as those will be required to build nvidia modules. Issue following command at terminal
$ aptitude -r install linux-headers-$(uname -r)
Now install required nvidia components. Following command will install and build nvidia modules, and also disable nouveau module.
$ aptitude install nvidia-kernel-dkms
Now we should create new Xorg server configuration file or modify existing to tell it to load nvidia module. nvidia-xconfig package make this task quite easy, install and execute it.
$ aptitude install nvidia-xconfig
$ nvidia-xconfig
Now reboot and check if system is using nvidia graphics driver. On start of xsession nvidia splash screen should be displayed. You can also confirm it by issuing following commands
First check if system is using glx module.
$ glxinfo | grep -i "direct rendering"
It should output "direct rendering: Yes"
If you do not have glxinfo then first install mesa-utils package then again issue above command and check output
$ aptitude install mesa-utils
Check if nvidia module loaded.
$ lsmod | grep nvidia
If it produces output like 'nvidia      11239499  45' or something similar (numbers could be different at your system) then nvidia module is loaded.
Just to be sure nouveau module NOT loaded, issue following command
$ lsmod | grep nouveau
It should NOT produce any output. If it produces output then something is wrong.
If you are planning to use NVIDIA Graphics Driver just for better disply and 3D rendering then it is almost finished. But if you want to run applications that uses NVIDIA CUDA for processing (like cudahashcat+) then you will also need to install CUDA drivers as below
$ aptitude install nvidia-cuda-toolkit nvidia-opencl-icd
 Now you should be able to use applications designed to utilize GPU.

Thursday, 4 July 2013

Boot KALI Linux in console mode (command line) as it was in BackTrack

A good thing i like in BackTrack was it boot in console mode. It is quite helpful if we have to run few console commands instead of using full GUI.

But Kali linux directly boot into graphical mode. To make it boot into command line mode we need to remove auto start of xdm service (or kdm or gdm based on your desktop manager) from current runlevel.

To do it first we need to know current runlevel. Issue following command

$ who -r

Remember your current runlevel from output of previous command. Mine is 2.

We also need to know service name of display manager we are running, check it with following command (replace 2 with your run level)

$ chkconfig --list | grep '2:on'

It will list all services set to autostart for run level 2. Look here for entry similar to gdm or kdm or xdm etc. I am running gdm3.

Ok, now we have identified which service (gdm3 in my case) we have to turn off at which run level (mine is 2).

Now issue following command to stop gdm3 service for run level 2.

$ chkconfig --level 2 gdm3 off

Now on next boot it will boot into command line login. After login use startx command to start xsession.

Failsafe: If something went wrong or later you decided to boot again into graphical mode, revert it back with following

$ chkconfig --level 2 gdm3 on

Note: I do not remember if chkconfig is pre-installed with Kali or i installed it manually. In case it say 'chconfig command not found' then you can install it with following command

apt-get install chkconfig

That's all. Happy pentesting with Kali linux :)

Friday, 7 June 2013

Using Kali Linux as main Operating System

If you are a fan of kali linux then probably you may want to use it as your main operating system (i do).
Here are following thumbs Up to use it as main OS
  • It is based on most popular rock solid debian wheezy, which is now stable release of debian.
  • It is as stable as debian wheezy
  • Large package repository. One can use almost all the packages that can be used on debian wheezy
  • Regular updates available.
And following thumbs Down for not to use it as main OS
  • It is designed for pentesting (with some modifications in kernel) and has lot of pentest/exploiting tools pre-installed
  • It work with root (super user) account

That's ok, but what's the verdict? Should we use it as main OS or not?
In my openion we can use it as main OS but we should use it with non-root user for regular use, and use root login only for pentesting.
Here is how you can create regular (non-root) user
Open terminal and type following to create new user (replace user1 with your desired user name)
useradd -m user1
Now set password for this user
passwd user1
    Enter desired password twice.
Add user to sudo group so  you can run common commands (like fdisk -l)
usermod -a -G sudo user1
4. Change default shell of previously created user to bash
chsh -s /bin/bash user1
All done! Now logout from root account and login as non-root user.
Enjoy Kali Linux as your main OS.
Note: If you like to strenghten the secuity then you should also setup firewall rules using gufw or firestarter.