Karthikselvakumar's log

Cursor Play With your neigbour System

Posted by: karthikselvakumar on: January 31, 2010

If you have more than one system and need to acces all with a single mouse ?

Wanna hack your neigbour node and drive him mad?


you can use this code to move the cursor

and with little modification you can emulate a whole mouse and keyboard functionalities too …

Download My code from here


To Do :


step i) run the server.class first in machine u want to control say A

java server <port_numbr 1000-65535>


step ii) run the client.class in second machine u have the mouse say B

java client <ip of machine say 10.2.3.1 > <port_number_server 1000-65535>


step iii) move  mouse in machine B so that it moves on machine A

Algorithm behind :

i)  get the mouse position from master machine

ii) send the position in a ‘encrypt‘ string with X and Y positions merged

as encrypt=X*10000+Y ( I use 10000  here assuming your screen resolution is not more than 10000X10000 :D )

iii) send the string to slave node using Socket output stream

iv) get the encrypt string and extract x and Y position  by

X=encrypt/10000;

y=encrypt – X;


v) Now move the position of slave machine by mousemove(X,Y) method

vi) You can add leftclick , right click and keyboard keys too as above  :)

Keyboard as Network Packet Monitor

Posted by: karthikselvakumar on: January 3, 2010

You can transform Your NUM lock and SCROLL lock led’s to monitor packets send and receive :)

Follow the simple steps below :

i) Installation:

Install tleds package  bye sudo apt-get install tleds

ii) Configure :

now configure the interface you use

say for ethernet  run tleds eth0

and for wirless  run tleds wlan0

Perform a restart :)

iii) Customize :

Now you can adjust the delay to very quick response to low response rate by adjusting -d paramter in tleds

for very quick run tleds  eth0 -d 1

for low speed run tleds eth0 -d 200

now you have  tranformed your keyboard to packet monitoring system as below :


enjoy :)

Facebook mouseclicks hack !

Posted by: karthikselvakumar on: January 1, 2010

I came across a facebook application which counts maximum number of clicks per second and thought of emulating it in java ;)

it is as simple as a crap code … with simple steps Download it from here

step 1:

I wrote a java code which automtes mouseclicks for N times by for loop

the code seems like :

import java.awt.Robot;
import java.awt.event.InputEvent;
/**
*
* @author karthik
*/
public class Main {
/**
* @param args the command line arguments
*/
public static void main(String[] args) throws Throwable {
Robot r=new Robot();

System.out.println(“Hurry up ! you have 10 seconds left “);
System.out.println(“This time you must have focused your mouse pointer on START button of facebook appln”);
r.delay(10000);

// TODO code application logic here
for(int i=0;i<10000;i++){
r.mousePress(InputEvent.BUTTON1_MASK);
System.out.println(“Clicking “+i+”th time “);
r.mouseRelease(InputEvent.BUTTON1_MASK);
System.out.println();
System.out.println();
}System.out.println(“Congrats ! you did it man  B-)”);

}
}

now save the code as Main.java in a directory c:\ in windows or /home in linux

step 2:

open terminal

compile the java code by running from the location where code is located by

javac Main.java

in the mean time open the facebook application

step 3:

Run the java code now this is critical part

java Main

( you can directly run this  by extracting Main.java.zip from above )

you will get a screen saying

“Hurry up ! you have 10 seconds left

This time you must have focused your mouse pointer on START button of facebook appln”

now focus your mouse pointer to the START button of fb appln

you will get a count more than 200 sometimes even 300 clicks per second ( depending on ur jvm )

for more clear details watch the video below :

Thank you :)

Disclaimer :

If you move your mouse button other than start button you will get random results around screen and may hang at times so keep the mouse pointer in START button for atleast a minute ;)

Music in Humble terminal

Posted by: karthikselvakumar on: January 1, 2010

i)  Are you in need of humble player which consumes least your memory

ii)  If your xserver doesnt open and your prompted to a black terminal   and need of a playing music..

iii) if your admin blocked gui

Dont worry still you can hear your favourite  Music files by following simple steps

Step 1:

install the sox for linux by running

sudo apt-get install sox

Step 2:

install mp3 codec for sox (since most of our songs are in .mp3 )

sudo apt-get install libsox-fmt-mp3

Step 3 :

Now your done with  :)

just locate the music folder and run the file

karthik@karthik: play  my-favourite-song.mp3

for eg:

karthik@Karthik:~/Music$ play I\’m\ So\ Available.mp3

I’m So Available.mp3:

File Size: 7.93M     Bit Rate: 239k
Encoding: MPEG audio    Info: 2009
Channels: 2 @ 16-bit   Track: 3
Samplerate: 44100Hz      Album: Akon – Collection
Replaygain: off         Artist: Akon Feat. Flo-Rida
Duration: 00:04:25.51  Title: I’m So Available

In:0.84% 00:00:02.23 [00:04:23.28] Out:107k  [  ====|====- ]        Clip:0

this is what you will see

Step 4:

not only listening you can also record from terminal

karthik@karthik: rec my-recording.wav

you will se output recording screen as

Input File     : ‘default’ (alsa)
Channels       : 2
Sample Rate    : 48000
Precision      : 16-bit
Sample Encoding: 16-bit Signed Integer PCM

In:0.00% 00:00:01.96 [00:00:00.00] Out:90.1k [      |      ]        Clip:0

now your recording will be saved in my-recording.wav file in music folder

enjoy with sox :)

Read CPU Core Temperature

Posted by: karthikselvakumar on: December 31, 2009

Well this is a tricky part where I have struggled for a function returning cpu temp in java and failed . Then I chose lm-sensor for this purpose .

step1

Installation :

install the package lm sensors for your linux distro

sudo apt-get install lm-sensors

step 2:

run sensors in terminal

if you have installed for first time probe it to kernel first

step 3: restart the system and try sensors now

I have a core2quad processor and i get temperature of four processors as

karthik@Karthik:~/Programs$ sensors
coretemp-isa-0000
Adapter: ISA adapter
Core 0:      +47.0°C  (high = +74.0°C, crit = +100.0°C)

coretemp-isa-0001
Adapter: ISA adapter
Core 1:      +37.0°C  (high = +74.0°C, crit = +100.0°C)

coretemp-isa-0002
Adapter: ISA adapter
Core 2:      +39.0°C  (high = +74.0°C, crit = +100.0°C)

coretemp-isa-0003
Adapter: ISA adapter
Core 3:      +46.0°C  (high = +74.0°C, crit = +100.0°C)

step 3:

call the process class of java and get back the string returned

import java.io.*;
class cpu {
public static void main(String []args) throws Exception
{
Runtime r=Runtime.getRuntime();
String f,temp,res=”";
int i=0,j=0;
f=”sensors”;
Process p=r.exec(f);
BufferedReader pin=new BufferedReader(new InputStreamReader(p.getInputStream()));
while((temp=pin.readLine())!=null)
{
System.out.println(temp);
}
}

}

Then make it flexible for your own purpose  by proper string parsing ….

Thank you !


Avatar (2009)

Posted by: karthikselvakumar on: December 28, 2009

I have to start with saying Cameroon dissaponted me …

Even storyline doesnt seems to be great but   visual effects are fantastic and real . Na’vi’s are the creatures in a planet pandora . For me their appearance resembles as traditional character Lord  Rama  . Avatar too is sanskrit word meaning phases of vishnu where one is Rama . I guess it may be a copy :P  .

No great explanation about the planets existence whats their origin where is it actually located .. blah blah  . The most humorous thing I  noticed is the base attack with lumps of fire ( where the place  people struggle for oxygen ,  but how combustion is possible  :P  ) .

I don’t know where to categorize this film .. either in animation or  comic series or scientific fiction or just an entertainer .. Only plus point makes the film still run is 3D . the existence of evya the holy god still confuses me whether film falls under spiritual r religious category :D .

The soul DNA transformation concept , electrochemical network of trees , the precious stones significance and  the hair like generic  interface between avatar and rest living creatures  could  be explained little more.

Its seems like Cameroon loosing his originality and resembles Speilsburg ’s Jurassic park. A must watch  film for kids < 10 :D .

Well if you fix on to watch this movie I recommend you  to watch it in 3D with surround sound ( don’t watch it out in your damn old pc and get disappointed )

Nokia Hacks and tips

Posted by: karthikselvakumar on: November 22, 2009

Try  this codes in your cell if you are not familiar with this one  b4..

This may help you when you are stuck up or trace some details out of your Mobile :

*3370# Activate Enhanced Full Rate Codec (EFR) – Your phone uses the
best sound quality but talk time is reduced my approx. 5%

#3370# Deactivate Enhanced Full Rate Codec (EFR)

*4720# Activate Half Rate Codec – Your phone uses a lower quality
sound but you should gain approx 30% more Talk Time.

#4720# Deactivate Half Rate Codec.

*#0000# Displays your phones software version, 1st Line : Software
Version, 2nd Line : Software Release Date, 3rd Line :
Compression Type.

*#9999# Phones software version if *#0000# does not work.

*#06# For checking the International Mobile Equipment Identity (IMEI
Number).

#pw+1234567890+1#
Provider Lock Status. (use the “*” button to obtain the “p,w” and “+” symbols).

#pw+1234567890+2#
Network Lock Status. (use the “*” button to obtain the “p,w” and “+” symbols).

#pw+1234567890+3#
Country Lock Status. (use the “*” button to obtain the “p,w” and “+” symbols).

#pw+1234567890+4#
SIM Card Lock Status. (use the “*” button to obtain the “p,w” and “+” symbols).

*#147# (vodafone) this lets you know who called you last.

*#1471# Last call (Only vodofone).

*#21# Allows you to check the number that “All Calls” are diverted to.

*#2640# Displays security code in use.

*#30# Lets you see the private number.

*#43# Allows you to check the “Call Waiting” status of your phone.

*#61# Allows you to check the number that “On No Reply” calls are
diverted to.

*#62# Allows you to check the number that “Divert If Unreachable (no
service)” calls are diverted to.

*#67# Allows you to check the number that “On Busy Calls” are diverted
to.

*#67705646# Removes operator logo on 3310 & 3330.

*#73# Reset phone timers and game scores.

*#746025625# Displays the SIM Clock status, if your phone supports this power
saving feature “SIM Clock Stop Allowed”, it means you will get
the best standby time possible.

*#7760# Manufactures code.

*#7780#
Restore factory settings.

*#8110# Software version for the nokia 8110.

*#92702689# Displays – 1.Serial Number, 2.Date Made, 3.Purchase Date,
4.Date of last repair (0000 for no repairs), 5.Transfer User Data.
To exit this mode you need to switch your phone off then on again.

*#94870345123456789# Deactivate the PWM-Mem.

**21*number# Turn on “All Calls” diverting to the phone number entered.

**61*number# Turn on “No Reply” diverting to the phone number entered.

**67*number# Turn on “On Busy” diverting to the phone number entered.

12345 This is the default security code.

Remember few of these codes may not work for recent nokia models ….

Ubuntu 10.04 Lucid Lynx

Posted by: karthikselvakumar on: November 20, 2009

Ubuntu 10.04 release named Lucid Lynx is the next release..

Well 10 second boot time is the main aim of this release it seems . I felt the high speed booting of my 9.10 karmic now from older hardy heron( 65 seconds to 25 seconds ) . still lucid aims at 10 seconds boo time as the main aim to achieve  . This release seems to be released at next year 2010 .

The 10 second boot time is acheived by equal partitoin of modules at start up  with:

i) loading the kernel and initramfs should take two seconds,

ii) driver loading, filesystem mounting, and other “plumbing” should take two seconds,

iii) launching Xorg should take two seconds

iv)  the remaining four seconds should be used to launch the desktop environment and other services that are part of the user’s session.

( if you are not well verse in this terms then please open your eyes after 10 seconds from start of booting  )

The computer should be fully booted and ready to use at the end of ten seconds


but as a sad part GIMP is removed from standard installation of ubuntu  when queried  developers say  :

  • the general user doesn’t use it
  • its user-interface is too complex
  • it’s an application for professionals
  • desktop users just want to edit photos and they can do that in F-Spot
  • it’s a photoshop replacement and photoshop isn’t included by default in Windows…
  • it takes up room on the disc


Im realy sad about this plot and really the fifth point  “it’s a photoshop replacement and photoshop isn’t included by default in Windows…”    . comparing a linux distro with a windows .

If they speak so then linux must be a simple skeleton with a sucky media player and a paint program as some others do.

well even it ’s sad ,  I guess it doesnt takes more than a couple of minutes to trigger sudo apt-get install gimp :D

Make your own OS

Posted by: karthikselvakumar on: November 18, 2009

Make your Operating System of your choice with five simple steps ( for linux geeks only ) :


Step 1: Download and install Reconstructor

Downloads click here

and run sudo dpkg -i reconstructor_2.8.1_by_hacktolive.org.deb



Step 2: Meta–>System Tools –> Recontructor

Now open the package reconstructor from system tools and enter your root password  . Click Next .

Step 3: Choose alternate cd option
on available options choose alternate cd to make a installable bootable OS  , or live cd fr live session of the cd

Step 4:  setting up the base

Now choose the working directory  and swap space to work up . Locate the iso image of your ubuntu CD or enter Ubuntu CD into cd rom

Step 5:adding up your own packages

Now you can add new packages or delete the unwamnted ones  and choose wallpapers , thems , the appln to boot on start up , the one you dont need with simple interface

and finally create disk will create your fresh piece of distro

You can have a try of remaster sys or  if you are really a linux geek try to do from scratch try the lengthy  step as in Linux  wiki  with squashfs tools

Now you can burn this iso image and distribute among your circle and call this as your   NEW DEVELOPED OS  as people say  :P

Is New Orkut Really New ?

Posted by: karthikselvakumar on: November 16, 2009

Well few days Back I heard something called new orkut . It took weeks before since last time I logged in  Orkut . Facebook attracted me more and some how addicted to it .Now heard about “New Orkut “ I came back to my old orkut :) .

 

Goodness I got invite from some one ( sad thing is New Orkut too is a Invite and use system ). Well when I saw try new orkut at top , Clicked it really expecting a amazing wonder as an Alice . But I seen a page something very similar to face-book which disappointed me a lot .

 

What they say new in this version are …

 

i) They say ‘ Friends updates are available to every one ‘ .. Do you guess this thing new as an FB user  :P

 

ii) second ‘Every one can comment on any friends notification , updates ,application and friend acceptance ‘ .

 

iii) A new thing I found interesting is Video chatting integrated with orkut ( pity on Linux users , it says ‘ OS not supported ‘)

 

iv) Best feature I found in this release is IE 6 is not at all supported :) .

 

v) Next humorous thing I found is adding a general sucky template  and five sticky colors  of their own  choice and  they said  ” Pick your favorite colors We’ve made orkut even more colorful “  ..

 

vi) Speed is the main thing they mentioned they have increased .. But instead of static pages I can see my page still buffering in status bar  ( stealing my pity small free  download limit I have :( )

 

vii) And the highlight of all is they mentioned moving chat bar from left side to right side as a new feature :D ( I guess the only thing they didnt imitate is the notification bar you can see under  as In face Book )

 

 

New Orkut

I guess it may take time to  digest this things and to switch over to new orkut .  The thing I like the most is the prefix Beta in Orkut  ( a word which can answer almost  all the bugs  user raises :P   )

You are

  • 2,886 Viewer of this blog .

Sweet tweets

tweet...

Enter your email address to subscribe to this blog and receive notifications of new posts by email.

Apt soul for my system

Ubuntu: For Desktops, Servers, Netbooks and in the cloud

 

February 2010
M T W T F S S
« Jan    
1234567
891011121314
15161718192021
22232425262728

Visitors Around the world

Watch videos at Vodpod and other videos from this collection.

My Tweets

Blog Runner

Licensed Product

Creative Commons License
projects by karthikselvakumar is licensed under a Creative Commons Attribution-Noncommercial-Share Alike 2.5 India License.
Based on a work at karthik.tk.
Permissions beyond the scope of this license may be available at karthikselva.noadsfree.com.

SocialVibe