Saturday, October 30, 2010

Linux Lessons part 1 Lesson 2

In the previous lesson, we discussed how to create folders with a common name, but with different number, e.g. a year number.
Our Case was to create folders, that our photos would sort out by their year.
E.g the photos taken in 2009 will go to the photo2009 folder.
Now, the first thing to consider is the folder reference. We won't speak about folders. In windows you call them folders. In Linux you call them directories. So you have 11 directories from 2000 until 2010. Is that ok? (If you have from 2001 until 2010 see again the previous lesson because there was a mistake in the code)
Now, in another directory, or in the same, you have 1000 photos or more, which have taken from 2000 until now.
Let's see one by one, our new tools we will need to sort them out.

1)date:

The program date, outputs the current date and time, if no arguments are given.
If you write in your terminal: man date , you will have a manual, or help which explains the arguments date can take.
There is an argument -r, which says



So, if we write date -r filename the output will be the date of the last time we modified that file.


But we only want the year taken (in our case).
How do we do that?
If you look in the man date again, you will notice a FORMAT part.


So, if we add a Format argument, the %G we'll get only the year.
Notice the syntax of date:


That means, write date, then the options (or arguments), the file and then the format after a + symbol.
In conclusion we write this:
date -r filename +%G
Voila:


So this is the date instruction!

2)variables
A variable is a random name we use to put things in it.
E.g name=Vasilis
mynumber=23
myage=20

name, mynumber and myage are variables.
Vasilis, 23 and 20 are the contents of each variable!
In lesson 1 we used in the for statement a variable! Can you guess its name?
Answer: Yes, its name was 'i'

3)``
To put an output of a program or command in a variable we use ``.
e.g. dateofphoto=`date -r filename`

4)mv
The mv instructions moves a file from a place to another.

5)cd
change directory

So, now we have our tools, we also have our folders.
So in your terminal write each line below followed by enter.

cd /path_where_the_photos_are
enter
for pics in *;do date_taken=`date -r $pics +%G`; mv $pics photos$date_taken; done


For any inquires or errors you notice let as know by:
email, facebook wall, or commnent.

The power of Linux, Lessons for Dummies part 1

Here is the beginning of a big Linux tutorial.
In most of the lessons we'll use bash.
Bash is the common Linux Shell, and stands for Bourne again shell!
The tutorials will have 2 parts: The case, that's the problem we face, a solution with common Windows knowledge, and a solution with Bash Script.
Vaslabs trials have made in an Ubuntu 10.04 Lucid Linux Machine, but there is no difference at all in every distribution you have. If you are new to Linux, Ubuntu is the best choice for you.

The Case:
We want to create 11 folders, each one will have the name photos and then a year number starting from 2000. In these folders we will put later some photos according the year they have been taken.

Solution:
1) In windows, or in Linux using file browser:
Go to the place you want to create the folders, right click, create folder, give it a name, e.g. photos2000, and keep doing that until you reach photos2010.
2)With a bash script:
So we want to make 11 folders in a specific location. It is not necessary to go to that location, so we won't change directory. Since you are new to Linux we won't even use a for, but will suggest that best solution later.
Even without a for the solution is faster.
So for that job will need:
1)a terminal (to write the commands)
2)the command mkdir which means make directory
3)the up arrow(it's on the keyboard)
4)and the path we want to make our folders.

So a simple solution is:
open the terminal.
write: mkdir /path/photos2000
press enter.
A folder named photos2000 has been created in /path.
then press the up arrow
The mkdir /path/photos2000 will show again.
Press backspace one time and then press 1.
now you will have mkdir /path/photos2001
press enter. etc...

But that is a very simple, and stupid solution. This is file browser thinking.
We can automate the above procedure by adding a for command.
So we'll need a couple of extra tools:
1) the for command
2)the let command (let allows mathematical operations)

So write that script instead.
for ((i=0;i<=10;i++)); do let number=2000+$i; mkdir "photos"$number; done
And press enter. The folders shall be created successfully. If you have any problems, don't
hesitate, write your problem on our facebook wall, or here as a comment.

Saturday, September 25, 2010

Kaspersky Lab provides its insights on Stuxnet worm

Kaspersky Lab's experts believe that Stuxnet manifests the beginning of the new age of cyber-warfare.

The recent Stuxnet worm attack is sparking lots of discussion and speculation about the intent, purpose, origins and -- most importantly – the identity of the attacker and target.

Kaspersky Lab has not seen enough evidence to identify the attackers or the intended target but we can confirm that this is a one-of-a-kind, sophisticated malware attack backed by a well-funded, highly skilled attack team with intimate knowledge of SCADA technology.

We believe this type of attack could only be conducted with nation-state support and backing.

"I think that this is the turning point, this is the time when we got to a really new world, because in the past there were just cyber-criminals, now I am afraid it is the time of cyber-terrorism, cyber-weapons and cyber-wars," said Eugene Kaspersky, co-founder and chief executive officer of Kaspersky Lab.

Speaking at the Kaspersky Security Symposium with international journalists in Munich, Germany, Kaspersky described Stuxnet as the opening of "Pandora's Box."

"This malicious program was not designed to steal money, send spam, grab personal data, no, this piece of malware was designed to sabotage plants, to damage industrial systems," he said.

"I am afraid this is the beginning of a new world. 90-ies were a decade of cyber-vandals, 2000's were a decade of cybercriminals, I am afraid now it is a new era of cyber-wars and cyber-terrorism," Kaspersky added.

Researchers at Kaspersky Lab independently discovered that the worm exploited four separate zero-day vulnerabilities. Our analysts reported three of these new vulnerabilities directly to Microsoft and coordinated closely with the vendor during the creation and release of software fixes.

In addition to exploiting four zero-day vulnerabilities, Stuxnet also used two valid certificates (from Realtek and JMicron) which helped to keep the malware under the radar for quite a long period of time.

The worm's ultimate aim was to access Simatic WinCC SCADA, used as industrial control systems that monitor and control industrial, infrastructure, or facility-based processes. Similar systems are widely used in oil pipelines, power plants, large communication systems, airports, ships, and even military installations globally.

The inside knowledge of SCADA technology, the sophistication of the multi-layered attack, the use of multiple zero-day vulnerabilities and legitimate certificates bring us to an understanding that Stuxnet was created by a team of extremely skilled professionals who possessed vast resources and financial support.

The target of the attack and the geography of its outbreak (primarily Iran) suggests that this was not a regular cyber-criminal group. Moreover, our security experts who analyzed the worm code insist that Stuxnet's primary goal was not to spy on infected systems, but to conduct sabotage. All the facts listed above indicate that Stuxnet development was likely to be backed by a nation state, which had strong intelligence data at its disposal.

Kaspersky Lab believes that Stuxnet is a working – and fearsome – prototype of a cyber-weapon, that will lead to the creation of a new arms race in the world. This time it will be a cyber-arms race

Sunday, September 12, 2010

Vaslook 1.0.2.1 NEW and STABLE

Our labs finished 2010 Vaslook series with critical improvements.
Vaslook is better than ever before.
It offers:
Yahoo E-mail notification
Notifies when network is down
Notifies for inappropriate Yahoo POP3 settings
Notifies for E-mails even on restart so you won't forget it.
Download it now and taste the light Vaslook experience!
Don't bother any more seeing every day your email!
Vaslook 1.0.2.1 is here!
Remember that you will need perl! Download Perl!

Sunday, August 22, 2010

New Password Maker

Vaslabs are delighted to announce the release of the new Password Maker that runs in Perl environment!

Requirements:
Perl 5.10 or earlier installed on your machine!

Download:
https://sourceforge.net/projects/passmaker/files/PasswordMaker.pl/download

Attention!
If you have the old version that doesn't mean that the new version it will generate the same passwords! This release hasn't any relation with the old version except the script name!

This project is under GNU license!

Wednesday, August 18, 2010

Mobile Remote Control

How about controlling your pc with your mobile phone?
Imagine this:
You are sitting on the sofa with your friends watching a movie on your laptop and you need to make your speakers louder. What do you do? But, of course, you reach your laptop and you press the appropriate button.
How about not leaving your cozy sofa and pressing a single button on your mobile to do this?
We've tried this and we show you how to do it.
You will need:
1)A pc with an external or internal bluetooth device.
2)A mobile phone that has the program Remote Control (we used Sony Ericsson Jalou but most of sony ericsson mobiles have this application)
3)This article :)

->Enable your pc bluetooth
->Make it discoverable
Right click on the bluetooth tray icon (right down on the taskbar), select Settings and click discovery.
->Take your mobile phone and find Remote Control (for our case it was in Entertainment)
->Choose the option you like (For the movie choose the media player)
->Select device (your pc daa :)
-> You should be able to see on your mobile screen the appropriate buttons.
->That was all.

Tuesday, August 17, 2010

From the author

Hey to you all! It was a wonderful year (September 2009-August 2010) ! We are glad that Vaslabs have such members as you! During this year we tried to focus on simple tutorials for computer beginners, but also to make sure that advanced users and young programmers wouldn't be indifferent as well.
With your support and feedback we have created some utilities and gadgets that make our life better.
We'll start from the simplest. DBHC was loved by new ones in assembly as it offers decimal, binary and hexadecimal converting. This year a new version of DBHC will be published. It will offer also and text converting. Then the final version of File Engineer. We are sad to announce that this is indeed the final version of it as the project has been closed from us.
Our christmas game, that we know has a few bugs, will be fixed, and a new completed version will be ready by next Christmas.
Our superpower Password Maker it is a high priority as well. New security fixes will be added so your password will be invincible. We shall make clear that this script is also available for windows users if Perl is installed.
Spastra Demo was announced in May 2010 and will be ready in January-February 2011.
And then a great utility was published by vaslabs.
Vaslook was immediately been published, had a lot of bugs, but with your feedback has been a very stable and reliable tool for your yahoo e-mail. It is the only program until now that been awarded with two awards! The softpedia free award and the Famous Why award.
What to expect from vaslabs this year?
We are growing really fast, so you can expect more articles and utilities.
Our team is growing us well so will expand our subjects and our programs. We have also entered Linux world so Linux users should expect something from us!
You can join us on facebook or to be a follower. Followers have full and free support for everything they want about computers.
Thank you all for your support
The author
Vasilis Nicolaou