ricardo dominguez on 3 Jan 2001 16:34:11 -0000


[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

<nettime> zapatista tribal port scan code* by EDT


zapatista tribal port scan code*

A port scan is not a crime. It is no different in spirit from counting the
windows of a building on a public sidewalk, or observing the number of
doors.
-- EDT, 2001


Chiapas, Mexico - January 3rd, 2000 - the Zapatista Air Force

"bombarded" the federal barracks of the Mexican Army with

hundreds of paper airplanes. Each one carrying a message to

counter the deafening noise created by the soldiers attempts

to silence their protests.

EZLN
http://www.ezln.org


In remembrance of this event the Electronic Disturbance Theater (EDT)

releases a digital translation of the Zapatista Air Force Action:

the *zapatista tribal port scan code.*



The distribution of the source code for the** zapatista tribal port scan
(ZTPS)**

will be followed by the release of a ZTPS Tool Kit on January 15th, 2001

through EDT’s home page.

Electronic Disturbance Theater
http://www.thing.net/~rdom/ecd/ecd.html


** zapatista tribal port scan (ZTPS) by EDT**

/* socketChecker -a simple port scanning class-
Opens a socket, checks it for a service, with a time-out.
Returns a String describing either the socket response, or
the result of the attempt to open the socket. Works for
both tcp-ip and udp services. A call to the factory method
checkSocket does it all (see below). Since the method
returns a String object after "time-out" milliseconds, you
might want to put the call *the checkSocket* method in it's
own thread.
*This code is completely free source
*If you download or use this code, please feel compelled to
make any improvements that you might make available to
the public domain.
*Utilize this code at your own risk - port scanning will
sometimes bristle the hairs of some sys admins.
As we know, the only thing a sys admin needs to do is
to complain (regardless of truth, and without responsible investigation),
for an Internet Service Provider (ISP) to pull the plug on a user.
*But if a socket is visible over the *public* Internet,
then a sys admin, (and everyone else), should expect
it to be scanned. A port scan is not a crime. It is no
different in spirit from counting the windows of a
building on a public sidewalk, or observing the number
of doors. If it sets off alarms, then it is the responsibility of
the sys admin to separate the potential threats from poetry,
free vision, or paper airplanes in public places.
Electronic Disturbance Theater
*/
import java.net.*;
import java.io.*;
public class socketChecker implements Runnable{
file://declarations
private String server;
private DatagramSocket dsock;
private DatagramPacket packet;
private int port;
private Socket socket;
private String response="";
private BufferedReader is;
private PrintWriter os;
public static final int TCP=0;
public static final int UDP=1;
private int type;
private boolean tcp; // if tcp true, then a tcp scan is done. if false,
udp.
private String message;
private boolean error=false;
// constructor - this is used by the factory method. You should not call
it.
public socketChecker(String server, int port, int type, String message) {
socket=null;
dsock=null;
packet=null;
this.server=server;
this.port=port;
this.type=type;
this.message=message;
response="trying; no connection"; // default response reports message
// if there is a problem connecting it will be caught as
// an exception in the run method...
}
// methods
/* This static factory method is what you use to scan a port
public static String checkSocket(String ahost, int aport,
int timeout, int type, String message);
ahost - the machine to scan
aport - the port to scan
timeout - tells the thread how many milliseconds to wait for the socket
to respond...
int type - you can use the static ints socketChecker.TCP or
socketChecker.UDP to choose tcp or udp scans...
message - a String used either to message a port (TCP), or as
the data for the UDP packet.
(use depends upon "type" of scan selected in type)
*/
public static String checkSocket(String ahost, int aport,
int timeout, int type, String message) {
socketChecker look= new socketChecker(ahost, aport, type, message);
Thread t = new Thread(look);
t.start();
try {
t.join(timeout);
} catch (InterruptedException e) {
System.out.println("InterruptedException e: " + e.toString());
}
return look.getResponse();
}
// getResponse simply returns the String response
private String getResponse() {
return response;
}
// the run method
public void run() {
if (type==TCP) {
tcp=true;
} else {
tcp=false;
}
if (tcp) {
response="trying TCP=\"" + message + "\"; no connection";
// open a tcp socket
try {
socket = new Socket(server, port);
} catch (Exception e) { // catches mainly security and unknown host
exceptions
response+="; " + e.toString();
error=true;
}
if (!error) { // if the socket is open Reader and Writer
try {
is= new BufferedReader(
new InputStreamReader(socket.getInputStream())
);
os= new PrintWriter(
socket.getOutputStream(),true /* autoFlush */
);
} catch (IOException e) {
response+="; IO problem; " + e.toString();
error=true;
}
if (!error) { // if Reader and Writer are open
response="sending TCP=\"" + message + "\"; no reply";
try {
os.println(message);
} catch (Exception e) {
response+=("; "+e.toString()+"="+message);
}
try {
response="sending TCP=\"" + message + "\"; reply="+is.readLine();
} catch (IOException e) {
response+="; " + e.toString();
}
}
}
} else {
// open a udp socket, send a packet, get response..
response="trying UDP packet=\"" + message + "\"; can't create";
try {
dsock=new DatagramSocket();
} catch (SocketException se) {
response="SocketException: " + se.toString();
error=true;
} catch (Exception e) { // mostly to gather the variety of possible
security exceptions
response+="; " + e.toString();
error=true;
}
if (!error) {
response="sending UDP packet=\"" + message + "\"; can't send";
try {
dsock.send(new DatagramPacket(message.getBytes(),
message.getBytes().length,
InetAddress.getByName(server),
port)
);
} catch (UnknownHostException e) {
response+="UnknownHostException:" + e.toString();
error=true;
} catch (IOException e) {
response+="IOException: " + e.toString();
error=true;
} catch (Exception e) { // mostly to gather the variety of possible
security exceptions
response+="; " + e.toString();
error=true;
}
if (!error) {
response="UDP packet sent=\"" + message
+ "\"; no reply";
byte[] buf= new byte[1024];
packet= new DatagramPacket(buf, buf.length);
try {
dsock.receive(packet);
error=true;
} catch (ArrayIndexOutOfBoundsException e) {
response="server trying to overflow buffer: " + e.toString();
error=true;
} catch (IOException e) {
response="IOException: " + e.toString();
error=true;
}
response= "UDP packet sent=\"" + message + "\"; reply=" + new
String(packet.getData(), 0, packet.getLength());
}
}
}
}
}


*******

End of zapatista tribal port scan code

*******
+ message + poetry packet +
}

}}


\+ Mayan Code+\

Zapatista Technology
Maya Time
Air Notes
Armed Words
Paper Force
EZLN 2001

San Andres
peace pact
signed accords
indigenous rights
Paz Digna
Fox promise

La Realidad
distributed encounters
beyond Seattle
las futuras
always already
future hacking

against neoliberalism
continuing repression
taking Land
taking communities
taking rights
Ya Basta!

new dawn
nightmare ends
jungle waits
silence breaks
nuestra arma
nuestra palabra

Yepa! Yepa!
Andale! Andale!
Arriba! Arriba!
Subcomandante Insurgente
Mexican Southeast
November 2000

post presidente
Ernesto Zedillo
assassination administration
going nowhere
Acteal 1996
peace justice
bad joke

sisters brothers
conciencia internacional
necesitamos difundir
la palabra
tomar accion
nueva fronteras

Lacandona dark
all power
for D.F

italian kilowatts
counter power
for Chiapas

virtual autonomy
real politics
not over
top down
cracks open
reality arcs

No Illegals
Mexico USA
Operation Gatekeeper
Border war
Every hour
Someone dies

amor rabia
suspended particles
adicciones ironicas
mariposa rotas
drift zones
futuras globales

auto nomedia
network art
tactical media
net strikes
hack tivismo
indy media

La Mar
Old Antonio
Don Durito
Little Pedrito
Commandante Tacho
Commandante Ramona

Zapatista Technology
Maya Time
Air Notes
Armed Words
Paper Force
EZLN 2001

}continue switch
}
}
}
}

*****
Communique' from the Clandestine Revolutionary
Indigenous Committee -
General Command of the Zapatista Army of National
Liberation. Mexico.

January, 2001.

To the People of Mexico:
To the Peoples and Governments of the World:

Brothers and Sisters:

This past December 22 it will have been 3 years since the Acteal killings.
On that day, 3 years ago, 45 children, women, men and old ones, all
indigenous, were massacred by a paramilitary group of Ernesto Zedillo's
government.

Those intellectually responsible for this crime against humanity continue
to go unpunished. The dirty war which made it possible continues. The
counterinsurgency doctrine which inspired it continues still. The
paramilitary structure which carried it out remains untouched. The
military protection of the assassins continues.

Despite what the lavish government publicity campaign says, nothing has
changed. There is nothing in place in Chiapas which would ensure that
Acteal will not be repeated.

For Acteal to be finally put in our country's past, it is necessary for the
truly guilty ones to be punished, it is necessary for the warlike viewpoint
to be finally abandoned and for there to be a serious commitment to the
political path. It is necessary that the paramilitary groups be dismantled,
it is necessary for the foundations of dialogue to be set through the
signals which were demanded.

The EZLN is calling on political, social and non-governmental organizations,
on intellectuals and artists, on religious men and women, on all honest
persons in Mexico and the world, to mobilize in demanding an end to the
policies
which made Acteal possible and the fulfillment of the 3 signals which were
demanded for the renewal of dialogue.

Democracy!
Liberty!
Justice!

>From the mountains of the Mexican Southeast.
By the Clandestine Revolutionary Indigenous Committee
-
General Command of the Zapatista Army of National
Liberation.

Subcomandante Insurgente Marcos.
Mexico, December of 2000.

EZLN
Zapatista National
Liberation Army

\ http://www.ezln.org\

{
dsock.receive(packet);

{{swtich_over}}

The distribution of the source code for the** zapatista tribal port scan
(ZTPS)** will be followed by the release of a ZTPS Tool

on January 15th, 2001 through EDT’s home page.

Electronic Disturbance Theater
http://www.thing.net/~rdom/ecd/ecd.html

#  distributed via <nettime>: no commercial use without permission
#  <nettime> is a moderated mailing list for net criticism,
#  collaborative text filtering and cultural politics of the nets
#  more info: majordomo@bbs.thing.net and "info nettime-l" in the msg body
#  archive: http://www.nettime.org contact: nettime@bbs.thing.net