Tuesday, December 2, 2008

Jeffrey Dahmer Borderline

Mozilla Songbird music player open

Mozilla Songbird is an open source music player which is customizable is under active development by Mozilla.

Songbird is a media player and a thousand other things.

Songbird novel features are:

  • GStreamer: a free cross-platform multimedia framework written in C programming language
  • mashTape : When listening to music with Songbird can see Flickr photos, YouTube videos, bios on last.fm, Google news and many other things related to the artist of the song.
  • Last.fm scrobbling : Excellent integration with Last.fm.
  • Smart Playlists reusable.
  • Concert Tickets: You can see upcoming events in your area, based on the artists in your music library.
  • Add-ons to the letter and many other features and functions.

Download version for Fedora Linux (other distributions )

Provided by Auralvance
Updated: 0.7.0 Rev 1 8/26/08

xJlara

Wednesday, November 26, 2008

Scavengers,detritivores And Decomposers




Fedora is a Linux-based operating system that brings the latest in free software and open source. Fedora is always free for anyone to use, modify and distribute. We build people around the globe who work together as a community: the Fedora Project. The Fedora Project is open and anyone is welcome to join. The Fedora Project is the newest, with the best free software and open content.

PS: I have a notebook Acer Aspire 5610z Atheros wireless card and Fedora 10 fully recognized all the hardware (including the webcam and wireless card)

xJlara

Tuesday, November 25, 2008

Mononucleosis Stomach Bloating

Welcome to Fedora 10 Linux Commands Hazardous


often want to install a program or want to configure a Linux service in our turn to internet to see if we find a howto to help us, many even sometimes directly copied and pasted the commands that appear in these guides directly to your computer executing those instructions and commands. But what happens if this is a malicious command?

see some of these commands:

# mkfs.ext3 / dev / sda This command formats the hard drive.

# :(){: This command will move all the folders and files in / dev / null Elymian pitch these these files permanently. Well I hope each of you to analyze and review what it does well when we turn to these guidelines, a recommendation is to have a virtual machine to test before. I invite you to comment if you know other commands as there are surely more than these 4 that I mentioned today. xJlara

Friday, November 14, 2008

Should Your Cervix Be High Or Low Before Menst



This example is 3 rooms with different capacities that record sales of 3 different promotions ($ 1000, $ 1500, $ 2000) what it does is sell and then see the sales report for each location. PD: It is a basic example ...

/ / Class Locales.java





import javax.swing .*; / **
* * @ author Jorge


private int totalventa; local1 Vector = new Vector (this.capacidad_local1)
local2 Vector = new Vector (this.capacidad_local2)
local3 Vector = new Vector (this.capacidad_local3)
/ / Number of Elements
to Store capacidad_local1 public int = 20; public int capacidad_local2 = 25;
capacidad_local3 public int = 33; / / Expenditures For Local
Fihjos gastos_local1 public int = 5000; gastos_local2 public int = 6000;
gastos_local3 public int = 7000;
Local public
() {

this.totalventa = 0;}




venderPromocion public void () {int

combo1 = 1000;
combo2 int = 1500;
combo3 int = 2500;
this.totalventa = 0;

int local = Integer.parseInt (JOptionPane.showInputDialog ("Select Locations: \\ n" +
"1 - Local 1 \\ n "+
" 2 - Local 2 \\ n "+
" 3 - Local 3 "));
if (local == 1) {
purchase
int = Integer.parseInt (JOptionPane.showInputDialog (" Select Promotion: \\ n "+
" 1 - Combo 1 $ 1000 \\ n "+
" 2 - Combo 2 $ 1500 \\ n "+
" 3 - Combo 3 $ 2500 "));
if (buy == 1)
purchase = combo1;
if (buy == 2)
purchase = combo2;
if (buy == 3)
purchase = combo3;

int qty = Integer.parseInt (JOptionPane.showInputDialog ("Select number of promotions:")) ;


/ / The Limit Purchases can not be greater than capacidad_local1


if (qty> this.capacidad_local1)
{JOptionPane.showMessageDialog (null, "You can buy a maximum" + +
this.capacidad_local1 "Promotions", "ALERT", JOptionPane.INFORMATION_MESSAGE )
Integer.parseInt (JOptionPane.showInputDialog ("Select number of promotions:"));}


this.totalventa = cannot * purchase;
local1.addElement (totalventa)
JOptionPane.showMessageDialog (null, "should Cancel $ "+ totalventa," ALERT "JOptionPane.INFORMATION_MESSAGE);}




if (local == 2) {Int
purchase = Integer.parseInt (JOptionPane.showInputDialog ("Select Promotion: \\ n" +
"1 - Combo 1 $ 1000 \\ n" +
"2 - Combo 2 $ 1500 \\ n" +
"3 - Combo 3 $ 2,500 "));
if (buy == 1) = combo1
purchase;
if (buy == 2) purchase = combo2; if (buy == 3)
purchase = combo3;

int cannot = Integer. parseInt (JOptionPane.showInputDialog ("Select number of promotions:"));
if (qty> this.capacidad_local2)

{JOptionPane.showMessageDialog (null, "You can buy a maximum" + +
this.capacidad_local2 "Promotions", "ALERT" JOptionPane.INFORMATION_MESSAGE)

Integer.parseInt (JOptionPane.showInputDialog ("Select number of promotions:"));}

this.totalventa = qty *
purchase;
local2.addElement ( totalventa)
JOptionPane.showMessageDialog (null, "must pay $" + totalventa, "ALERT" JOptionPane.INFORMATION_MESSAGE)



} if (local == 3) {
purchase
int = Integer.parseInt (JOptionPane . showInputDialog ("Select Promotion: \\ n" +
"1 - Combo 1 $ 1000 \\ n" +
"2 - Combo 2 $ 1500 \\ n" +
"3 - Combo 3 $ 2500 "));
if (buy == 1) = combo1
purchase;
if (buy == 2)
purchase = combo2;
if (buy == 3)
purchase = combo3;


int cannot = Integer.parseInt (JOptionPane.showInputDialog ("Select number of promotions:"));
if (qty> this.capacidad_local3)
{JOptionPane.showMessageDialog (null, "You can buy a maximum" + +
this.capacidad_local3 "Promotions" "ALERT" JOptionPane.INFORMATION_MESSAGE)
Integer.parseInt (JOptionPane.showInputDialog ("Select number of promotions:"));}

this.totalventa = cannot * purchase;
local3.addElement (totalventa)
JOptionPane.showMessageDialog (null, "must pay $" + totalventa, "ALERT" JOptionPane.INFORMATION_MESSAGE)


}}



verVentasTotales public void () {

/ / Report

Local 1


String Output = "Index \\ tValor \\ n";

for (int i = 0; i
output + = i + "\\ t" + local1.elementAt (i) + "\\ t" + "\\ n";}




ventanaSalida = new JTextArea JTextArea ();
ventanaSalida.setText (Output);

JOptionPane.showMessageDialog (null, ventanaSalida, "LOCAL REPORT 1" JOptionPane.INFORMATION_MESSAGE)

/ / Report
Local 2
OUTPUT2 String = "Index \\ tValor \\ n";
for (int i = 0; i
OUTPUT2 + = i + "\\ t" + local2.elementAt (i) + "\\ n";}


ventanaSalida2 = new JTextArea JTextArea ();
ventanaSalida2.setText (OUTPUT2)

JOptionPane.showMessageDialog ( null, ventanaSalida2, "REPORT LOCAL 2" JOptionPane.INFORMATION_MESSAGE)


/ / Report Local 3

OUTPUT3 String = "Index \\ tValor \\ n";

for (int i = 0; i
OUTPUT3 + = i + "\\ t" + local3.elementAt (i) + "\\ n";}


ventanaSalida3 = new JTextArea JTextArea ();
ventanaSalida3.setText ( OUTPUT3)

JOptionPane.showMessageDialog (null, ventanaSalida3, "LOCAL REPORT 3" JOptionPane.INFORMATION_MESSAGE)
}}












/ / Class Main.java









import javax.swing .*;
/ **
* * @ author Jorge
* / Public class Main {private static int x; private static boolean continue = true; / ** * @ param args the command line arguments
* /
public static void main (String [] args) {
/ / TODO code application logic here Local milocal = new Local ();

do
{/ / Main Menu
x = Integer.parseInt (JOptionPane.showInputDialog ("Select Options: \\ n" + "1 - Sales \\ n" +
"2 - Sales Report \\ n" +
"3 - Exit"));

switch (x) {


/ / Sales

case 1: milocal.venderPromocion ();


/ / ask for another operation such as calculating sales or continue selling

int b = Integer.parseInt (JOptionPane.showInputDialog ("Press: \\ n "+
" 1 - continue \\ n "+
" 2 - Quit \\ n "));

if (b == 2)
continue = false;
break;

/ / Reports, reports show of the 3 rooms together

case 2: milocal.verVentasTotales ();


/ / ask for another operation such as calculating sales or continue selling
b = Integer.parseInt (JOptionPane.showInputDialog ("Press: \\ n" + "1 - continue \\ n" +
"2 - Quit \\ n"));
if (b == 2) continue =
false; break;

/ / exit system
case 3: continue = false;;

default: break;




}} while (continue); / / will be output from


JOptionPane.showMessageDialog (null, "Have a nice day", "Close System", JOptionPane.INFORMATION_MESSAGE) }}



Let's see some screenshots



Local Menu









Menu Promotions






Number of Promotions to Buy



Total to Pay for Purchase
Sales Report


xJlara

Wednesday, October 22, 2008

How To Hack Pokemon On Mac

Example Vector Linux 2008 National Meeting in

has finally arrived on the Ninth Meeting UdeC Linux really I am pleased to participate in this event.

The meeting will be held on 22, 23, October 24 (
more information.) For
behind or those unable to attend for work ... may attend on Saturday 25 to Gnome Day also

UdeC
http://live.gnome.org/DiaGNOME For more information visit.

x Jlara


Sunday, October 19, 2008

1950's Women In Corsets

UdeC Vectors, Arrays, Arrays or whatever you call ....

I always thought that one of the concepts we learn in any language has programming arrangements or vectors are even more so when we are mere apprentices and we do not have any basis solid knowledge in this. In Java an array is a set of variables (called elements or components) that stores values \u200b\u200bof the same type. (More

).



The following example is taken and adapted from the book
" How to Program JAVA" fifth edition of Deitel

I had the opportunity to purchase this great book and really good (the publisher been reduced by 40%).

/ / Creating an array
/ / http://geekslinuxchile.blogspot.com/
/ / Adapted from the book "How to Schedule Java "Deitel


{public class under public static void main (String args []) {
int array [];
/ / Declare the reference in accordance arregl0 = new int [10]; / / Create under
String output = "Index \\ tValor \\ n";


/ / append each string elemntos the output under for (int counter = 0; output + = counter counter + "\\ t" + array [counter] + "\\ n";
System.out.println (output);

}}




As we do not assign any value to the array elements each element is printed with a default value (in this case 0).




(Soon .... will continue with the manual)
x Jlara < arreglo.length; contador ++ )



Thursday, October 16, 2008

Free Angel Blade Episodes

Learning JAVA Programming in JAVA




One of the programming languages \u200b\u200bthat always caught my attention is
JAVA
for portability and is also multi pltaforma.
is why in this section I'll upload all my progress in this language ... not promise much as I am starting from scratch.

will use Java in Ubuntu 8.04 in a graphical environment to see how to install XFaces java visit the following link in this block (JDK on Linux Installing
) Creating our first program (Hello World)


NOTE: Save file with the same name and extension class. java (
HelloWorld .
java) Compile javac
holaMundo.java
run java HelloWorld


(always follow this sequence with all the examples)



/ * First year of Java
http : / / geekslinuxchile.blogspot.com / Author: Jorge Lara Cravero * /

import javax.swing .*; public class HelloWorld {public static void main (String [] args) { String message = "Hello World"; JOptionPane.showMessageDialog (null, message, "Hello, World!" JOptionPane.INFORMATION_MESSAGE) System . exit (0);
}}














This second script looks for a letter or word in a string


Include the class Input / * Jorge Lara Cravero
http://geekslinuxchile.blogspot.com/ * /

{public class

seek public static void main (String args []) {


Input data = new Input ();
(".... Enter string System.out.println ....") ;
dato.getValue letters = String ();

sentence ...."); System.out.println (".... Enter
dato.getValue String phrase = ();

String output = "is at index "+ letras.indexOf (sentence); System.out.println (output);

}}
code runs as follows:









If


note I wrote

Jorge Lara and I find the word in lower case
lara







Obviously Lara! = lara
Note: images correspond to a more complete code because if you review the example all the console will

addition if you want your system says it is not! should be made a condition if - else considering that when the word is not the system will throw a -1

would be something like int a = letras.indexOf (sentence); if (a == -1 ) guess what happens

guess what else happens


x Jlara

Wednesday, October 15, 2008

Stranded With A Mirror

fake YouTube pages to attack computers






Hackers are taking advantage of social networks to send links to supposed videos of YouTube, where users have to update the software viewing.


Computer security specialists warn that hackers are using fake pages
YouTube
to deceive Internet users to open their computer to malicious software. Hackers send

alleged links to Google Video portal and links connect replicas YouTube realistic pages, indicating that it needs a software upgrade required to view video. OK, this update allows the hacker to install malware that could disable keys and steal data or take the control allow the affected computer. Chances are that victims do not realize it, since the pirated software will then send the real YouTube site showing the video promised.
This deception through fake YouTube pages, according to AFP
agency is part of a growing trend of hackers to use the popular social networking sites where individuals share links and programs.

Source (
)

Tuesday, October 14, 2008

Bath After A Brazilian

Creating a Trigger in MySQL



In this short article will show how to create a trigger (or trigger) in MYSQL to tell us which user deleted a record in a table manufacturers in our computer database (see database item of this notebook).

Although the 1 am will realize this manual in the afternoon because I was working with a partner on this and I realized that mysql support triggers easily perform insert default records as

-

CURRENT_USER ( )
=> Insert the user who performed the surgery for free, - CURRENT_DATE () => Insert the date performed the surgery for free, - CURRENT_TIME () => Insert the time it was performed the surgery for free, => Insert the date and time it was performed the surgery for free,
But inserting records such as the code or name for the record to delete (or update) with a trigger requires more skill I hope to be clarified now.


NOTE:
MYSQL does not support more than 1 trigger in the same table;

Hands to work wing Creating tables (note: the database can call computer or the name they wish)

SET SQL code sql_mode = "NO_AUTO_VALUE_ON_ZERO"
CREATE TABLE `articles` (
CODIGOART `` int (11) NOT NULL, `NAME

` varchar (100) default NULL, `PRICE

` int (11) default NULL, `CODFRABICANTE ` int (11) NOT NULL,

PRIMARY KEY (`CODIGOART`, `CODFRABICANTE`), KEY `


CODFRABICANTE` (`CODFRABICANTE`)

) ENGINE = InnoDB DEFAULT CHARSET = latin1;

INSERT INTO `articles`
(CODIGOART ``, `name`, `PRICE`, `` CODFRABICANTE)
VALUES (100, 'MOUSE', 4230, 5),
(101, ' DELL Notebook ', 439223, 3),
(102,' Tower 50 DVD + R ', 7110, 1),
(104,' Base Notebook ', 22514, 8),
(105 , "Computer Assembled PIV ', 178214, 10), (106,' Multimedia Keyboard PS / 2 ', 4491, 6),

(107,' Aspire 5610 Notebook ', 466223, 4),

(108, 'Laser Printer', 12591, 7)
(109, 'Headphone and microphone Gamer', 18923, 9),
(110, 'USB notebook lamp', 9000, 5),
(111, 'mouse pad', 891, 10) ,
(112, 'Key PAD', 2691, 1),
(112, 'Screen Cleaner', 4500, 8),
(113, 'Backpack Notebook', 29723, 6);
CREATE TABLE `manufacturers` (
`CODE` int (11) NOT NULL, `NAME

` varchar (100) default NULL,

PRIMARY KEY (`CODE`)
) ENGINE = InnoDB DEFAULT CHARSET = latin1;
INSERT INTO `manufacturers` (`CODE`, `name`) VALUES

(1, 'National Isumo and co. ")

(3,' Dell Computer Inc. '), (2,' HP '),

(4,' International Steel '),
(5,' Genius'), (6, 'PC Tronix'),

(7, 'Sony'),

(8, 'Kensington'),
(9, 'Logitech'),
(10, 'National Importing');

ALTER TABLE `articles`
articulos_ibfk_1 `ADD CONSTRAINT` FOREIGN KEY (`CODFRABICANTE`) REFERENCES `manufacturer` (`CODE`) ON DELETE CASCADE ON UPDATE CASCADE;

Well we already have 2 related tables (manufacturers and articles) now create a new table we will call changes.
CREATE TABLE `changes' (
` id `int (11) NOT NULL,` nombre_art

`varchar (50) default NULL,
` user `varchar (50) default NULL,


`DATE` TIMESTAMP (0) NOT NULL DEFAULT '0000-00-00 00:00:00 ', PRIMARY KEY (`id`)
)
ENGINE = InnoDB DEFAULT CHARSET = latin1;


This table will store the item id, name, user, date and time to delete a table record manufacturers. Building


Trigger CREATE TRIGGER `` informatica. Fabricantes_before_ins_tr `` BEFORE DELETE ON `computing`. `Manufacturers`

FOR EACH ROW BEGIN INSERT INTO
SET id = old.CODIGO changes, nombre_art = old.Nombre, username = CURRENT_USER (), date = CURRENT_TIMESTAMP;
END;


In this case I used it
old
is a delete

in the table but if it were a
update or insert to use the alias New
.

Now we can only eliminate any record of the table manufacturers and reviewing changes in the table as has been almacenda information.

Note: To create trigger must have super user attributes database engine.
(If it fails check the semicolons and Blogger did remove some special characters to upload the information.)

more information in wikipedia x Jlara.

Friday, October 10, 2008

Cervical Mucus Increase And Late Period

changing the MAC on Linux


ago
more or less a month I had to install a linux server as a gateway, firewall and Proxi ... Known in a hotel in the region. The situation was as follows:

1. There was a dedicated Internet connection and in its place was a DHCP (VTR) company that stands to capture the MAC Address of network card so only provide the internet connection to a computer. Well originally existed a router with Mac Clone option to share one a single network connection. I for one had to physically separate the network into 2 networks .. up there all ok ... but as well I had to configure a firewall and Internet sharing me I found the need to clone the MAC address of the router to the card eth0 Linux (Debian 4.0) ...


The way to do it. 1 .- Install

macchanger
aptitude install (apt-get install) 2 .- Stop network / etc / init.d / networking stop
3 .- Clone MAC


$
macchanger-m XX: XX: XX: XX: XX: XX eth0

With the latter I enter the MAC address custom

4 .- Start

network / etc / init.d / networking start


With that and the output can gain Internet for eth0.

No doubt you can do many things and although the MAC guada Machango and load automatically, to make sure I create a small script that is loaded along with the launch of the network (to keep the MAC).

EXAMPLES



# macchanger eth1 Current MAC: 00:40:96:43: ef: 9c [wireless] (Cisco / Aironet 4800/340) Faked MAC : 00:40 : 96:43: ef: 9d [wireless] (Cisco / Aironet 4800/340)

# macchanger - endding
eth1 Current MAC: 00:40:96:43: e8: ec [wireless] (Cisco / Aironet 4800 / 340)
Faked MAC: 00:40:96:6 f: 0f: f2 [wireless] (Cisco / Aironet 4800/340)
# macchanger - another eth1
Current MAC: 00:40:96:43:87:1f [wireless] (Cisco/Aironet 4800/340) Faked MAC: 00:02:2d:ec:00:6f [wireless] (Lucent Wavelan IEEE)

# macchanger -A eth1
Current MAC: 00:40:96:43:39:a6 [wireless] (Cisco/Aironet 4800/340)
Faked MAC: 00:10:5a:1e:06:93 (3Com, Fast Etherlink XL in a Gateway)
# macchanger -r eth1
Current MAC: 00:40:96:43:f1:fc [wireless] (Cisco/Aironet 4800/340) Faked MAC: 6b:fd:10:37:d2:34 (unknown)
# macchanger --mac=01:23:45:67:89:AB eth1
Current MAC: 00:40:96:43:87:65 [wireless] (Cisco/Aironet 4800/340)
Faked MAC: 01:23:45:67:89: ab (unknown)
 #. / Macchanger - list = Cray 
Misc MACs: MAC Vendor Num
--- --- ------
 065 - 00:00:7 d - Cray Research SuperServers, 
Inc 068 - 00:00:80 - Cray Communications (formerly Dowty Network Services)
317 - 00:40: a6 - Cray Research Inc.
 Visit the site macchanger 
creator
 Jlara 

Saturday, September 27, 2008

Kylie A – Sleep

Delete old logs files in Linux

A common task of maintaining Linux operating systems (and that extends to most operating systems based on or clones of Unix) is cleaning the log files. Both the operating system as a database engine few data and proprietary processes can generate large amounts of log files. In the long term, it is necessary to remove these files as we occupy space, have become obsolete and we tend to complicate the search.
 Therefore, based on the original publication "List / Delete files by date in Linux as we can see from the shell to search for and delete old files. Needless to say, that the commands listed below are candidates to be part of a shell script and is likely to be executed by cron. 

Well, enough of words and see some practical examples:
 Find files updated three days ago in the current directory: 

cd / var / log
find-name \\ *. log-mtime +3
 Search 
updated files until three days ago in the current directory and delete them:
find. -Name \\ *. log-mtime +3-exec rm {} \\;

Find the updated files back one day and show its full path:
find / var / log / [az] * \\ *. log-mtime +1
As in the second case, if we delete the files returned by the previous command:
find / var / log / [az] * \\ *. log-mtime +1-exec rm {} \\; addition, we can refine the search more by using the argument-mmin-mtime instead of:

*-mtime n, search for files modified n * 24 hours ago (n days ago) PS: This line can be used to delete old backups if we set a cron to backup a database or other files as tgz. etc.

find *. tgz-mtime +6-exec rm {} \\; (


eliminate having a week old)


source (http://www.luchoedu.org/)






Spot Dangers Worksheet

What are the SQL transactions?








are a set of SQL statements that have the quality to run as a single unit that is running or not running all or none.
A tables
able to support transactions are called
ACID (Atomicity, Consistency, Isolation
, Durability)
English (Atomicity, Consistency, Isolation & Durability)




Atomicity: =>
Something that can not be divided, I mean all queries are treated as one and they only run when all are correct in the event of a mistake does not run anything. Consistency: => This is linked to referential integrity, ie can only be write valid data in compliance with the declared data types and referential integrity.

Isolation: => Each transaction is executed independently of other transactions or rather one after another, after these transactions are executed (successful or wrong) the changes are visible to other users. Durability: =>

When a transaction completes successfully the changes become permanent.
  1. Example

  2. Let the following example how important it may be a transaction.

  3. Suppose that two vendors store availability consult the LCD and only have one is stock (as these are hot) to make a sale and one is a TV in stock.

    only with SQL

    First

Vendor 1

: SELECT stock FROM TV;

Seller 2: TV

SELECT FROM stock;

Seller

1: UPDATE

TVs SET stock = stock -1;

Seller 2: UPDATE

TV SET stock = stock -1;

SELECT First to make each vendor will see on your screen that is available 1 television.

The seller 1

sell the TV leaving the stock to 0, then the seller 2

does not know that the TV has been sold and will sell TV (think there is stock) and the stock will be -1 and the latter has been sold by the seller 1

. If real life was a customer will have to wait longer than normal to reach your TV. Now same Transactions Seller 1: START TRANSACTION; Vendor 1

: SELECT stock FROM TV;


Seller 1: UPDATE

TV SET stock = stock -1;

Seller

1: COMMIT , (running)

Seller 2:

START TRANSACTION;

Seller 2:

SELECT stock FROM TV;

Seller 2: ROLLBACK; (out of the transaction without doing anything more)

Seller 2: Tip client not availability and asks if you want to buy and wait a few days until there is stock again.

As we have seen the operations were computer allows data consistency after the first vendor to finish the operation performed seller 2 queries. Example 2 (Something more work)

This example shows how to perform operations in a transaction have 1 table called departments with the following structure and records


CREATE TABLE `departments` (

CODIGODEP `` INTEGER (11) NOT NULL DEFAULT '0 ', `NOMBREDEP

` VARCHAR (100),
BUDGET `` INTEGER (11),

PRIMARY KEY (`CODIGODEP`) ) ENGINE = InnoDB

INSERT INTO `departments` (`CODIGODEP`, `NOMBREDEP`, `Budget`) VALUES (1, 'Computer', 300000), (2, 'Personal', 200000), (11, 'Quality', 150 000), (13, 'Security', 450,000), (56, 'HR', 900,000), (77, 'Administration' 1500000);


and now create a new departamentos2 table and assign 30% of the money from the budget of each department departamentos2 table, ie departmental budget subtract 30% of its budget and assign to departments departamentos2 table. (The structures are equal and incuse keep the same codes and names of departments)




departamentos2 `CREATE TABLE` (`CODIGODEP

` INTEGER (11) NOT NULL DEFAULT '0 ', ` NOMBREDEP `VARCHAR (100), BUDGET` `INTEGER (11),
PRIMARY KEY (` CODIGODEP `)
) ENGINE = InnoDB



now

transactions


START TRANSACTION;

departamentos2 insert into `select`

codigodep, nombredep, budget departments * `from` 0.30; September update departments budget = budget - (budget * 0.30 ) COMMIT;




The result has been a table of all records of departments 1 and budgets of the two tables have been properly modified by adding and subtracting 30% respectively.






This will prevent any other user is modifying the table when performing the operation departments
Jlara


Friday, September 26, 2008

How Fast Does A 4hp Motor Go

Install Java Development Kit (JDK) and Java Runtime Environment (JRE) in Ubuntu Linux console

This short tutorial will explain how to install the correct JRE version of Linux, because when we will download files from the Sun

page there are so many that sometimes do not know what to install. Installation

tested ubuntu 7.10 desktop, Ubuntu 8.04 desktop and server.

Packages needed:


=>
sun-java6-bin

: Sun Java Runtime Environment (JRE) 6 =>
sun-java6-demo
: Sun Java Development Kit (JDK) 6 demos
=>
sun-java6-jdk => sun-java6-jre : Sun Java Runtime Environment (JRE) 6


Install Sun Java 6

Open a shell (terminal) and type the following to install JDK and JRE:
  1. $ sudo apt-get install sun-java6-bin sun-java6-jre sun-java6-jdk
  2. here displays a message indicating all the dependencies of packages to install, press S to accept.
  3. Default install Java version
  4. Ubuntu Linux comes with update-java-alternatives utility updates all the alternatives that belong to a development kit for Java. To select, Sun JVM as provided type:
  5. $ sudo update-java-alternatives-s java-6-sun
also need to edit a file called / etc / jvm
. This file defines the default search order system for jvm (java virtual machine). Each list of JVM in JAVA_HOME should be in this file. The default system JVM is the first one available from top to bottom. Open
/ etc / jvm


$ sudo vi / etc / jvm

sure to add
/ usr/lib/jvm/java-6-sun
at the top of the list JVM.
The file should read:


/ usr/lib/jvm/java-6-sun

/ usr / lib / jvm / java-gcj
/ usr / lib / jvm / ia32-java-1.5.0-sun
/ usr/lib/jvm/java-1.5.0-sun

/ usr

Save and close the file. (Esc: wq)

Setting environment variable
also need to set JAVA_HOME and PATH (system wide) configuration . Open your $ HOME /. Bash_profile or / etc / profile:
$ vi $ HOME / .bash_profile
Add line:
export JAVA_HOME = / usr/lib/jvm/java-6-sun export PATH = $ PATH: $ JAVA_HOME / bin

Save and close the file. (Esc: wq)

Test your new JDK

Type the following command to display the version:
$ java-version
should display a message like this
:


java version "1.6.0_03"

Java (TM) SE Runtime Environment (build 1.6.0_03-b05) Java HotSpot


(TM) Server VM (build 1.6.0_03-b05, mixed mode)

(If you see this happiness you already have everything you need installed)


First program (Java Hello World)
$ vi holaMundo.java

Type the following code: public
   
class HelloWorld {



public static void
main (String

[

]

args) {
       
System . out.println ( "Hello, World!" ) ; }} Save and close the file. holaMundo.java compile and run the program by typing two commands:
holaMundo.java $ javac $ java HelloWorld out: Hello, World!



Aspartamewithdrawaldizziness

Customizing our Social Networking Linux Logo

Linux logo is a small script that displays the logo of the layout Linux (have only used it with Debian) on the initial screen of Linux.
It general use debian to install servers without graphical environment so it was interesting to have this application each time you access the computer.




Installation:
 


apt-get install linuxlogo
(You can also use aptitude)
. 

Once installed edit the following file as root
etc / inittab
and headed to the next line
which is the first virtual terminal (eg pressing Alt + F2 will open the tty 2).

modify the line leaving this menera:

1:2345: respawn: / sbin / getty -f / etc / issue.linuxlogo
38400 tty1 (You can do the same for each terminal so that we all display the logo)

Now restart: / etc / init.d / restart

linuxlogo
Now every time we get into the team we appear the logo. If we also view the putty to ssh to connect from Windows to Linux linux_logo> / etc / motd There

logos for all distribution with Linux (if installed on redhat, fedora, centos or cuaquier Deriba should use yum instead of apt)

Jlara

Walkie Talkie Distance

and public information also

This post, although much has been said on this topic, will discuss the large container of information that is the Internet and social networks

.





But what about information on the Internet?, Usually given by good user any information held on a particular topic. It could be true, but ... Can we trust?, If we are a little paranoid ...





What about social networks?
a public person or a company. Because ... why not put me through George Bush or

Vladimir Putin ?, Or for example could pass myself off as an engineer at CERN (which is now very fashionable) and spreading rumors about the operation of the same or even why not, the end of the world

?

How much damage can a false information on the Internet?,

depends, and influenced by many factors: repetition, through publication, etc. So it is becoming increasingly necessary to know and quantify the most amount of information that is "flowing" through the network, to detect and mitigate as far as possible these risks.

Arce José María Guillén S21sec labs

Plastic Pants For My Husband

Linux

In recent years it has grown malware designed for Linux, infecting many computers and servers with this operating system.

Although Linux is used by a minority compared with the number of Windows users, is happening as Mac OS X



, both operating systems are becoming more popular users. For this reason, cybercriminals are creating malware developed to specifically affecting Apple computers or computers with Linux. As highlighted in Sophos Security Report July 2008 cybercrime, the problem of malware against Apple is currently very small compared to the launched against Windows, but this does not mean no risk. Since the appearance of the first malware to Mac OS X in late 2007-created for economic reasons-have been several attempts by hackers to infect computers and steal from Mac the RST-B malware designed for Linux, has infected a large number of computers and servers that use this operating system. According to data from SophosLabs, the highest infection level Linux / RST-B with compromised computers are in the U.S., followed by China and Germany.

Although Linux is presented several distributions, the kernel, or core on which they develop different versions is the same, and for this reason the virus created to run on any Linux distribution, but may not have the same effect.
(source vnunet.es)

New York State Driver's Template

virus is blocking transactions and MySQL tables

By default, MySQL runs with autocommit mode

activated. This means that once you run a command that updates (modifies) a table, MySQL stores the update on disk.

This mode

autocommit can only be cleared if are working with InnoDB tables


(which are also the only ones to support referential integrity in MySQL).


SET AUTOCOMMIT = 0;

After disabling autocommit (set autocommit = 0;) obligations will be used obligatorily COMMIT to save or ROLLBACK to undo. To disable autocommit mode for a single series

command, you can use the command

START TRANSACTION
   




Example: create a new table in the database
Company: `CREATE TABLE` departamentos2 (

CODIGODEP
`` INTEGER (11) NOT NULL DEFAULT '0 ', `NOMBREDEP
` VARCHAR (100), BUDGET
`` INTEGER (11) DEFAULT NULL,
PRIMARY KEY (`CODIGODEP `)
) ENGINE = InnoDB
and now will insert records departments table in a transaction departamentos2

START TRANSACTION;
SELECT @ A: = budget

FROM departments WHERE codigodep = 11 INSERT INTO
departamentos2 (codigodep, nombredep, budget )

VALUES (11, 'test', @ A);

COMMIT;

In the example above the budget of the department store in the variable 11
@ A
and then allocate the budget Table departamentos2 now an example where all data object any one department in the table
departamentos2
START TRANSACTION;
SELECT @ A: = budget, @ B: = codigodep, @ C: = nombredep

FROM departments WHERE codigodep = 33;
INSERT INTO departamentos2 (codigodep , nombredep, budget)
VALUES ( @ B, @ C, @ A


)
COMMIT;

In the preceding example copying an entire department to the departments table 2 ....
can add and allocate budgets as follows:
START TRANSACTION; SELECT @ A: = BUDGET FROM departments WHERE codigodep = 11;
departamentos2 UPDATE SET BUDGET = BUDGET + @ A WHERE codigodep = 33; COMMIT;

In this last example update the department's budget 33 of the table
departamentos2 adding the entire budget of the department table 11


departments

When you perform a SQL transaction to be taken into account that the table is locked


leaving only enabled to the one we are doing





Tuesday, September 9, 2008

Answers Tohardy Weinberg Problems In Lab 8

Increases creativity

pages Mean infected during the first half of 2008 is three times higher than the same period in 2007.
Eleven million

malware Sophos has just introduced a new safety report examines trends in existing and emerging security and has identified that criminals are increasingly creative in using new techniques in their attempts to defraud money Internet users.
is estimated that the total existing malware exceed eleven million of that Sophos receives about 20,000 new samples of suspicious software every day, which is a new malicious program every four seconds
The report
Sophos reveals that most attacks are designed to try to fool the traditional security systems such as scanning e-mail. During the first half of 2008 has seen an explosion of web-based attacks, the hackers choice for economic reasons. 90 percent of these pages, using Trojan horses and spyware are legitimate websites. Some of them, belonging to household brands and Fortune 500 companies have been hacked through SQL injection attacks. The report
 Sophos Web site that hosts more malware is Blogger (Blogspot.com), the publishing system posts, owned by Google, which accounts for two percent of all malware that resides on sites worldwide. 

addition, Sophos Security Report details attempts by hackers and spammers to take advantage of Web 2.0 sites such as Facebook or LinkedIn, attack devices with operating systems other than Windows, such as Apple Macs and Linux, and the likelihood of attacks emerging against users of Apple's popular iPhone.
http://www.vnunet.es
)


Friday, September 5, 2008

Bushnell Trophy Magnifier

cybercriminals Applying SQL Part 4

! - @ Page {size: 21cm 29.7cm; margin: 2cm} P {margin-bottom: 0.21cm } ->

start with September 1, 1920 new exercises to continue our tutorial database (see third

).

To begin this part we have to create a new database to which we will call

company which in turn will have 2 related tables

employees and departments

. CREATE DATABASE `company`; USE `company`, (to proceed to create the tables only if we are in console mode) CREATE TABLE `departments` (`CODIGODEP ` INTEGER (11), `NOMBREDEP PRIMARY KEY (` CODIGODEP `)) ENGINE = InnoDB
CREATE TABLE `employee` (`RUT ` VARCHAR (10),
`name` VARCHAR (100),
`LAST` VARCHAR (200), `DEPARTMENT` INTEGER (11), PRIMARY KEY (` `RUT), ) ENGINE = InnoDB ALTER TABLE EMPLOYEES ADD FOREIGN KEY (` DEPARTMENT `) REFERENCES` departments `(` CODIGODEP `) ON DELETE CASCADE ON UPDATE CASCADE

Now insert records into the tables created


INSERT INTO `departments` (`CODIGODEP`, `NOMBREDEP`, `Budget`) VALUES
(1, 'Computer', 1000000),
(2, 'Personal', 9000000),
(13, 'Security' 500000),
(56, 'HR', 5000000),
(77, 'Administration', 2000000);
COMMIT INSERT INTO `

employee` (`RUT`, `name`, `LAST`, `DEPARTMENT`)
VALUES ('10333444-1 ',' Sofia ',' Quintana ', 13),
('10352097-6', 'Maria', 'Contreras', 77),
('11111111-1', 'Pedro' , 'Tapia', 2),
('12052097-0 ',' Jorge ',' Lara ', 1),
('13456789-2', 'Maria', 'Bathroom', 13),
('16152094 -2 ',' Jose ',' Perez ', 1),
('21345678-7', 'Manuel', 'Rodriguez', 56),
('23567876-4 ',' Ignacio ',' Race ' 2),
('6435456-6 ',' Peter ',' Asnar ', 56),
('7654231-9', 'Elias', 'Soto', 13);
COMMIT;
(All data are invented and have no relation to real life people xD)






Exercises:

! - @ page {size: 21cm 29.7cm; margin: 2cm} P {margin-bottom: 0.21cm} ->



1. Get the names of employees


SQL statement: SELECT NAME FROM

EMPLOYEES;



Query Result:


2. Get the names of employees No repeats Note
have to create a new worker with a name will be repeated in this case Perez to run this query (this because so far we have no name repeated) INSERT INTO
employees (RUT , NAME, LAST NAME, DEPARTMENT)
VALUES ('13987345-9 ',' Miguel ',' Perez ', 13);

SQL statement: SELECT NAME FROM
EMPLOYEE GROUP BY NAME;
Result query: (as we only see a Perez, thanks to the Group By)
3. Get all the data employees whose last name is Perez SQL statement: SELECT * FROM
EMPLOYEES WHERE NAME = 'Perez';
Query Result:




4. Get all the details of employees whose last name is Perez and those named Contreras SQL statement: SELECT * FROM
EMPLOYEES WHERE NAME = 'Perez' or NAME = 'Contreras';

Results query:

5. Get all the information of employees working in the department 1
SQL statement: SELECT RUT, NAME, LAST NAME, DEPT FROM EMPLOYEE INNER JOIN DEPARTMENT CODIGODEP ON WHERE DEPARTMENT = DEPARTMENT = 1;
Query Result:

6. Get all the information of employees working for the Department 1
and the department 13 Important Note:
As the rut is a primary key can not repeat a worker in another department and we will fail primary key, the solution would include a field
rut in the department table and thus we would have more or less solved this but as I did at the beginning and not create new relationships Confucianism'll add a field called department 2 in the Employees table. ALTER TABLE EMPLOYEE ADD
DEPARTAMENTO2 INTEGER DEFAULT NULL;


The default value of the fields is Null (ie non-zero and empty).
now assign to workers to another company department. (Those who are in Department 1 also take you to 13)
DEPARTAMENTO2 UPDATE EMPLOYEES SET = 13 WHERE department = 1;
And now to carry out the sentence requested in the exercise
SQL statement:
SELECT RUT, NAME, LAST NAME, DEPARTMENT DEPARTAMENTO2 FROM EMPLOYEES WHERE DEPARTMENT = 1 OR DEPARTMENT AND DEPARTAMENTO2 = 13 = 1 OR DEPARTAMENTO2 = 13;
Note: I asked 1 to 13 in both fields to filter the query correctamete.

Query Result:



7. Get all the details of employees whose last name starts with P. SQL statement: SELECT * FROM
EMPLOYEES WHERE NAME LIKE 'P%';
Note:




LIKE is another keyword that is used in the WHERE clause
. Basically, LIKE

allows you to make a search based on a pattern rather than specifying exactly what you want (as in IN
) or determine a range (as in BETWEEN

). In this case
LIKE 'P%'; deliver all surnames beginning with P Query Result: 8. Get the total budget for all departments. SQL statement: SELECT NOMBREDEP, BUDGET FROM DEPARTMENTS;
Query Result:
9. Get the number of employees in each department.

SQL statement: SELECT COUNT (DEPARTMENT), NOMBREDEP FROM DEPARTMENTS INNER JOIN EMPLOYEES ON DEPARTMENT = CODIGODEP
DEPARTAMENTO2 = CODIGODEP GROUP OR BY NOMBREDEP;
NOTE: This query
I have considered that there are employees who work in 2 departments at once for it to do the count department, but turn in the inner join enter

departamento2 Query Result:

10. Get a listing full each employee for each employee including data syu department.

SQL statement: SELECT

NOMBREDEP, FIRST, LAST, RUT
FROM DEPARTMENTS INNER JOIN EMPLOYEES ON
CODIGODEP = DEPARTMENT OR ORDER BY CODIGODEP = DEPARTAMENTO2 NOMBREDEP;

NOTE:
This refers to the me the most was to make the select optimal to join Enner department and employees as mentioning as I have employees come in 2 departments at a time (it is a more realistic example)
:



11. Get a complete listing of each employee for each employee including the names next to their name and budget departament0
SQL statement: SELECT

, LAST, RUT, NOMBREDEP,

BUDGET FROM DEPARTMENTS INNER JOIN EMPLOYEES ON

CODIGODEP =
DEPARTMENT OR ORDER CODIGODEP = DEPARTAMENTO2 BY NOMBREDEP; Note: Users who belong to two departments appear with your budget in both departments.)

12. Get a first and last names of employees working in departments with a budget greater than $ 500,000

SQL statement: SELECT
, LAST
FROM DEPARTMENTS INNER JOIN EMPLOYEES ON CODIGODEP = DEPARTMENT OR CODIGODEP = DEPARTAMENTO2 WHERE BUDGET> 500000 ORDER BY NOMBREDEP;



13. Get a data from the departments whose budget is greater than the average price of all departments. SQL statement: SELECT

NOMBREDEP, BUDGET FROM DEPARTMENTS WHERE
BUDGET> (SELECT AVG (BUDGET) FROM DEPARTMENT)
14. Get only the names of the departments that have more than 2 employees.
SQL statement:
NOMBREDEP SELECT FROM EMPLOYEE INNER JOIN DEPARTMENT ON DEPARTMENT OR = CODIGODEP
DEPARTAMENTO2 = CODIGODEP
NOMBREDEP GROUP BY HAVING COUNT (DEPARTMENT)> 2;
I personally believe that this consultation is more complete indication also how many employees does the department above.

SELECT COUNT (*) As AMOUNT, NOMBREDEP
DEPARTMENTS FROM EMPLOYEE INNER JOIN DEPARTMENT ON
OR = CODIGODEP DEPARTAMENTO2 = CODIGODEP NOMBREDEP
GROUP BY HAVING COUNT (DEPARTMENT)> 2;





15. Add new Quality department with code 40000 and budgeted $ 11 .. DEPARTMENTS (CODIGODEP, NOMBREDEP, BUDGET)
VALUES (11, 'quality', 40000); Select * from departments;

16 . Add a new employee to department quality (Esther Vazquez rut 23456789-9).
SQL statement: INSERT INTO
EMPLOYEES (RUT, NAME, LAST NAME, DEPARTMENT) VALUES (23456789-9, 'Esther', 'Vazquez', 11);

17. Apply a 10% budget cut to all departments.

SQL statement: UPDATE DEPARTMENTS SET BUDGET = BUDGET * 0.9;


18. Department workers reallocate 11 (Quality) to the department 1 (computer).
SQL statement: UPDATE

SET DEPARTMENT EMPLOYEES WHERE DEPARTMENT = 1 = 11;

19. Remove all employees of the department 1 (computer).

Note:
As I indicated there are employees who are on 2 departments and disposed Computer departamento2 also be removed from the computer science but this is not so this year will be settled in 3 steps.



Important: Always be very careful in making a direct delete the database because if you do not assign a condition
Where all records will be deleted. (It is no exaggeration to make a backup before doing a delete) remember that here there is no undo command ....




1 .- First remove all empledos working in Department 1 and not having a job in a second department (for departamento2 default should be NULL)


SQL statement:
DELETE FROM EMPLOYEES WHERE DEPARTMENT = 1 AND DEPARTAMENTO2 NULL;
2 .- As I is for previous consultations in column 2 only department employees are assigned to the department 13 will update the information so that those who are computer (which by default are also on the dept 13) will be assigned only to the department 13, but as your first apartment.


<=> SQL statement:

UPDATE EMPLOYEES SET WHERE DEPARTMENT = DEPARTAMENTO2 DEPARTAMENTO2 = 13; 3 .- Now that you have my updated information proceed to remove the information from leaving depratamento2 NULL field (remember that the same information already in the department and this column is just to keep the information repeated departamento2)



SQL statement: UPDATE EMPLOYEES SET
DEPARTAMENTO2 = NULL WHERE DEPARTAMENTO2 = 13;
Let's see how it looks our table select * from employees;
20. Remove all employees who work in a department with a budget greater than $ 2000000.
SQL statement:
DELETE FROM EMPLOYEES
A
INNER JOIN DEPARTMENTS A = CODIGODEP
DEPARTMENT ON WHERE BUDGET> 2000000
;

Note:
Here I used an inner join again to join the tables but for the delete to succeed you must assign an alias to the table used in this If my nickname is A
(if you look my sentence says
DELETE A FROM. ...).

stay Let's see how our information .... now only should we have employees in departments with budgets of up to $ 2000000 SELECT RUT, FIRST, LAST, NOMBREDEP DEPARTMENT, DEPARTAMENTO2 FROM EMPLOYEE INNER JOIN DEPARTMENT ON DEPARTMENT = CODIGODEP;

21. Remove all employees. Note:

this statement is the easiest of all

, but do not forget to make a
backup before and if your boss gave them the order is always the possibility that you will regret or that we need that information. SQL statement: DELETE FROM

EMPLOYEES; see how it turned out our information (although it is ..... there is nothing)
SELECT * FROM EMPLOYEES;
It was all for now .... any public consultation comments.