May 252012
 

I do things the easiest way that gets the job done.  Someone asked me recently about mounting a shared windows drive in Linux from bash.  They stated they normally mount it through dolphin using:

smb://username:password@ip_address/SHARED_DRIVE

That works until you need to copy files via rsync or some other bash method.  The solution is actually very simple:

mount -t cifs //ip_address/SHARED_DRIVE /mnt/directory -o user=username,password=user_password_on_windows_share,uid=500,gid=500

Just be sure you replace uid=500 with the users id in linux and gid=500 with the users group id in linux in order to be able to write files/directories with the proper permissions.  Of course the mount directory, /mnt/directory, also must exist.

If you get an error about “mount error(12): Cannot Allocate Memory

the fix is:

Edit the windows registry

Set “HKLM\SYSTEM\CurrentControlSet\Control\Session Manager\Memory Management\LargeSystemCache” to “1″.
 
Set “HKLM\SYSTEM\CurrentControlSet\Services\LanmanServer\Parameters\Size” to “3″.
 
Restart the “server” service.

Feb 112012
 

Lets face it, John the Ripper has been around a long time and the reason its been around a long time is because its damn good at cracking passwords.  Yea, hashcat and oclhashcat are great for gpu cracking, but it doesn’t support as many algorithms as JTR.  So, imagine my surprise when I fire up John The Ripper on backtrack 5 64 bit and find out it is using a single CPU.  That is letting a potential 75% of my system sit there wanting to do something.  Luckily the fix is easier than fixing a sandwich.

If you already have jtr installed, you may want to see my john tips article.

First, lets grab the jumbo sourcecode….

Continue reading »

Oct 112011
 

….I can assure you, if I can’t do it in bash, it doesn’t need to be done…..the other side of the argument was, well, bash isn’t multi-threaded…..hahahahaha …..really??? Run this……

#!/bin/bash
 
set -m # Enable Job Control
trap '' 2 # disable ctrl + c so you can't stop this bitch
rand=${RANDOM} # lets find some big random number
 
let POWEROFTWO=${rand}**2 # and since its not big enough, make it ^2
 
	for i in `seq ${POWEROFTWO}`; do # start HUGE num jobs in parallel
		echo "99999999999^99999999999" | bc
		sleep 1 &
	done
 
# Wait FOREVER for jobs to finish cause you can't stop me now nemo
while [ 1 ]; do fg 2> /dev/null; [ $? == 1 ] && break; done

May 182011
 
openvas gsd interface

So backtrack 5 still using the older openvas-2 series and I actually like the newer version.  So here are the instructions on getting the latest version installed. This will install these versions: openvas libraries 4.0.5-1; openvas scanner 3.2.4-1; openvas client 3.0; openvas manager 2.0.4-1; openvas admin 1.1.1-1; gsa 2.0.1-1; gsd 1.2.0-1; openvas cli 1.1.2-1 as packaged by the opensuse build service.

 

NOTE: June 23, 2011 — if the version numbers have changed, you can browse the repository address and update this document accordingly.  Also, yes, this does work on my bt5 install on three different systems.  I am installing on a 4th system now and will update the steps because I think I may have left 1 or 2 out.

Continue reading »

May 052011
 

Did you ever wish you could start certain scripts only when you are bringing the network up and then stop them when bring the network down?

For the longest time, I was using wicd to manage network connections.  At some point and time I decided to take a look at NetworkManager.

Using network manager, you can use the dispatcher to run scripts based on network connection, runlevel, etc.

This is how I got it working in gentoo linux and a few example scripts.

Continue reading »

May 052011
 

I am sure many people have heard that verizon has asked google to remove tethering applications from their App Store.

Luckily I already had it installed but in case you don’t you can get it from here android-wifi-tether

I am running 2.0.7

In linux, you need to make sure you have this in the kernel config:

Device Drivers --->
  [*] Network device support --->
    USB Network Adapters --->
      [*] Multi-purpose USB Networking Framework
        <*> CDC Ethernet support
        <*> CDC EEM support
        <*> Simple USB Network Links (CDC Ethernet subset)
          [*] Embedded ARM Linux links
  [*] USB Support --->
    <*> USB Modem (CDC ACM) support
    <*> USB Wireless Device Management support

Continue reading »

Aug 152006
 

I am teaching three Distance Learning Classes for the Maysville Community & Technical College beginning in the fall semester.

The two courses are:
NIS230 – Introduction to Unix (using Fedora Core Linux)
CIS200 – MySQL & PHP Programming

The first course, NIS230, is a repeat of the Winter course using a revised edition of the book with an additional chapter on Linux System Security. The book includes Fedora Core 2 installation CD’s which have a bug if it is installed on a dual-boot system and since the latest version of Fedora Core 4 is out, I will be handing these CD’s out to students and recommend they use this edition instead (or any other Linux distribution of their choice). As an alternative to installing Fedora Core Linux, we also offer the option of using the Adios bootable Linux distribution (or any bootable Linux distribution will suffice). The book & lecture content will be updated, as needed, since Linux is a rapidly changing operating system that remains in constant development.

The combined MySQL + PHP course will be split into two 8 week courses, and using the excellent book Build Your Own Database Driven Website Using PHP & MySQL from SitePoint.

Aug 052005
 

The two presentations I will be giving cover MySQL Database Administration (August 1 & 2) and PHP Programming Basics (August 3 – 5).

MySQL Database Administration: (from the web site): This two-day, instructor-led course will provide an overview of MySQL database administration tasks. MySQL is an open source relational database product that is available for both the Windows and Unix operating system platforms. MySQL is frequently used to support data-driven web sites. This workshop will provide an overview of what MySQL is and how it works; coverage of the MySQL installation process on the Windows platform, and basic MySQL database administration tasks.

Prerequisite knowledge: Familiarity with fundamental database design concepts and SQL (Structure Query Language).

Audience: This course is intended for IT professionals who are responsible for developing and/or administering a MySQL database.

PHP Programming Basics: (from the web site) This three-day, instructor-led course is designed to provide an overview of PHP server-side programming. Topics include: PHP server installation and configuration; PHP statement syntax, data types and variables; control structures; functions; integrating PHP and HTML; passing data between pages; and creating and testing PHP server-side scripts.

Prerequisite knowledge: Basic knowledge of HTML.

Audience: This course is intended for IT professionals who are responsible for developing and maintaining PHP/HTML web applications.

Information about the KCTCS (from the web site): The Kentucky Community and Technical College System (KCTCS) recognizes the need for skilled instructors to teach emerging technologies. This need will be addressed during the Working Connections Institute 2005, a one week training session at West Kentucky Community and Technical College in Paducah Kentucky. After two successful Working Connections Institutes in 2003 and 2004, KCTCS is once again very proud to offer this technical training opportunity to KCTCS IT faculty & staff. Choose from 2-day, 3-day, and 5-day workshop sessions; each of which is designed to help prepare you to teach in the constantly changing world of Information Technology.