<?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>Bosco López</title>
	<atom:link href="http://www.boscolopez.com/?feed=rss2" rel="self" type="application/rss+xml" />
	<link>http://www.boscolopez.com</link>
	<description>El rincón de mis pensamientos</description>
	<lastBuildDate>Sun, 01 Aug 2010 02:47:01 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0</generator>
		<item>
		<title>Servidor de Correo</title>
		<link>http://www.boscolopez.com/?p=344</link>
		<comments>http://www.boscolopez.com/?p=344#comments</comments>
		<pubDate>Sun, 01 Aug 2010 02:47:01 +0000</pubDate>
		<dc:creator>Bosco López</dc:creator>
				<category><![CDATA[Linux]]></category>

		<guid isPermaLink="false">http://www.boscolopez.com/?p=344</guid>
		<description><![CDATA[En el año 2004, escribí para la web de la asociación AMIGA un manual de como instalar y configurar un servidor de correo con Sendmail bajo linux, pues hoy me lo he encontrado en una web en la que respetaron los créditos, así que aprovecho y lo dejo publicado aquí. OJO ES DE 2004!!!! escrito [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.boscolopez.com/wp-content/uploads/2010/08/gfx7.gif"><img class="alignleft size-medium wp-image-345" title="gfx7" src="http://www.boscolopez.com/wp-content/uploads/2010/08/gfx7-264x300.gif" alt="" width="264" height="300" /></a>En el año 2004, escribí para la web de la asociación AMIGA un manual de como instalar y configurar un servidor de correo con Sendmail bajo linux, pues hoy me lo he encontrado en una web en la que respetaron los créditos, así que aprovecho y lo dejo publicado aquí. <strong>OJO ES DE 2004!!!!</strong></p>
<table border="0" cellspacing="1" cellpadding="0" width="100%">
<tbody>
<tr>
<td width="70%" align="left" valign="top">escrito por Bosco López</td>
<td align="right" valign="top"></td>
</tr>
<tr>
<td colspan="2" valign="top"></td>
</tr>
<tr>
<td colspan="2" valign="top">23-05-2004<br />
<strong>Primeramente decir que este manual se ha utilizado y seguido en la  Fedora Core 1, pero también se ha utilizado con Red Hat, así que es  posible que en alguna otra distro las rutas difieran de las que aquí se  nombran.</strong></p>
<p>Nos ponemos manos a la obra y lo primero que tendremos que hacer es comprobar  que tenemos una serie de paquetes instalados y de no ser así instalarlos  cuanto antes.rpm -q sendmail sendmail-cf imap m4 make cyrus-sasl cyrus-sasl-md5</p>
<p>De esta forma comprobaríamos si los paquetes están instalados,    pero si por ejemplo nos devolviera que alguno de ellos no está instalado    o por casualidad ninguno está instalado ejecutariamos lo siguiente<br />
<strong>Para los que usen yum:</strong><br />
yum install sendmail sendmail-cf imap m4 make cyrus-sasl cyrus-sasl-md5</p>
<p><strong>Para los que usen apt:</strong><br />
apt-get install sendmail sendmail-cf imap m4 make cyrus-sasl cyrus-sasl-md5</p>
<p>Ahora antes de seguir vamos a dejar claro como haremos el alta de cuentas de    usuario, para que después no surjan problemas ni quebraderos de cabeza,    así que fijaros bien.</p>
<p>Como es casi seguro que algún día tengamos más de un dominio     en nuestro servidor, podría ocurrir que una persona se diera de alta    como <strong>pepito</strong> el cual pertenecería al dominio1.com, pero    al agregar el dominio2.com dos meses después a nuestro servidor, otro    usuario quiere registrarse con el nombre de pepito pero con cuenta de email    en dominio2.com:<br />
pepito@dominio1.com<br />
pepito@dominio2.com<br />
Para poder tener este tipo de usuarios sin ningún tipo de problema las    altas en vez de crearlas así:</p>
<p>useradd -s /sbin/nologin pepito</p>
<p>Las crearemos con un login del tipo <strong>usuario</strong>, para que quede    más claro a pepito del dominio1.com le llamaremos usuario1 y a pepito    del dominio2.com le llamaremos usuario2:<br />
useradd -s /sbin/nologin usuario1<br />
useradd -s /sbin/nologin usuario2</p>
<p>Más adelante explicaré como los diferenciaremos, para que a cada    uno le llegue su correo.<br />
Lógicamente a cada usuario hay que darle una contraseña por lo    que usaremos el comando:<br />
passwd usuario1</p>
<p>También asignamos la contraseña SASL para permitir la autentificación    vía SMTP:</p>
<p>saslpasswd2 usuario1</p>
<p>Bien, ya sabemos como agregar a los usuarios que tendrán cuenta de correo    en nuestro servidor.<br />
Ahora estableceremos los dominios que hospedamos en nuestro servidor; para ello    tendremos que ir al archivo que se encuentra en la siguiente ruta:</p>
<p>/etc/mail/local-host-names</p>
<p>Lo editamos con nuestro editor favorito y lo dejariamos tal que así:<br />
dominio1.com<br />
dominio2.com<br />
mail.dominio1.com<br />
mail.dominio2.com</p>
<p>Volvemos a abrir nuestro editor preferido y creamos el siguiente archivo &#8220;relay-domains&#8221;,    donde incluiremos los dominios que tienen permitido el envío de correos,    normalmente local-host-names y relay-domains tienen el mismo contenido, pero    en caso de que vosotros querais excluir a algún dominio para que no pueda    enviar correo, no tendriais que agregarlo en este archivo.<br />
Por ejemplo vamos a pensar que &lt;b&gt;dominio2.com&lt;/b&gt; no queremos que    envie correos.<br />
Lo que tendriamos en relay-domains sería lo siguiente:<br />
dominio1.com<br />
mail.dominio1.com<br />
&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211;<br />
Si días después decidieramos que dominio2.com si puede enviar    correos, tendriamos lo siguiente:<br />
dominio1.com<br />
mail.dominio1.com<br />
dominio2.com<br />
mail.dominio2.com</p>
<p>Este archivo lo guardaremos en la siguiente ruta <strong>/etc/mail/</strong><br />
Vamos ahora a configurar las ips que podrán enviar correo sin autentificar    y las ips a las que tenemos denegado enviar correo aunque se autentifiquen.<br />
Para ello editamos el siguiente archivo <strong>/etc/mail/access</strong><br />
localhost.localdomain RELAY<br />
localhost RELAY<br />
127.0.0.1 RELAY<br />
192.168.1.254 RELAY<br />
# Otros servidores de correo en la LAN y que tiene permitido<br />
# enviar correo hacia otros servidores.<br />
192.168.1.253 RELAY<br />
192.168.1.252 RELAY<br />
# Algunas máquinas que tiene permitido enviar correo<br />
# sin autenticarse, pero no enviar correo hacia otros servidores.<br />
192.168.1.251 OK<br />
192.168.1.250 OK<br />
#<br />
# Lista negra. Se rechaza correo que se diríja hacia y desde:<br />
roberto@fresnedoso.com REJECT<br />
spammingSuX.com.mx REJECT<br />
213.60.51.20 REJECT</p>
<p>Los que están como RELAY no necesitan autenficarse ante el SMTP.<br />
Ahora antes de ponernos a configurar el sendmail.mc, configuraremos a que usuario    llegarán los correos de <strong>root</strong>; para ello vamos a /etc/aliases    y al final del todo, ponemos:</p>
<p>root: usuario0 &lt;- O el nombre de usuario que tenemos nosotros en la máquina,    eso a gusto del consumidor <img src='http://www.boscolopez.com/wp-includes/images/smilies/icon_razz.gif' alt=':P' class='wp-smiley' /> </p>
<p><strong>Configuración del sendmail.mc</strong><br />
Primero una vista preliminar y después un archivo de configuración    por defecto que os debería servir a casi todos añadiendo algunas    cosillas <img src='http://www.boscolopez.com/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>
<p>Si se utiliza la siguiente línea, habilitada por defecto, se permitirá    realizar autenticación a través del pueto 25 por cualquier método,    incluyento PLAIN, el cual se realiza en texto simple. Esto implica cierto riesgo    de seguridad.<br />
define(`confAUTH_OPTIONS&#8217;, `A&#8217;)dnl</p>
<p>Si comenta la anterior línea con dnl, y se utiliza en cambio la siguiente    línea, se deshabilitará la autenticación por de texto simple    en conexiones no seguras (TLS), de modo tal que solo se podrá autenticar    a través de métodos que utilicen ciframiento, como sería    CRAM-MD5 y DIGEST-MD5.<br />
define(`confAUTH_OPTIONS&#8217;, `A p&#8217;)dnl<br />
Si se desea utilizar SMTP autenticado para equipos no incluidos dentro de /etc/mail/access,    se requieren descomentar las siguientes dos líneas, eliminando el &#8216;dnl&#8217;    que les precede:</p>
<p>TRUST_AUTH_MECH(`EXTERNAL DIGEST-MD5 CRAM-MD5 LOGIN PLAIN&#8217;)dnl<br />
define(`confAUTH_MECHANISMS&#8217;, `EXTERNAL GSSAPI DIGEST-MD5 CRAM-MD5 LOGIN PLAIN&#8217;)dnl</p>
<p>Deshabilitar las funciones que definen trabajar sobre la interfaz 127.0.0.1    y recibir correo de dominios inexistentes precediendo con &#8216;dnl &#8216; en las siguientes    líneas:<br />
dnl DAEMON_OPTIONS(`Port=smtp,Addr=127.0.0.1, Name=MTA&#8217;)dnl<br />
dnl FEATURE(`accept_unresolvable_domains&#8217;)dnl</p>
<p>Habilitar las siguientes lineas y adaptar valores para definir la máscara    que utilizará el servidor:</p>
<p>MASQUERADE_AS(`mi-dominio.com&#8217;)dnl &lt;- *Nota 1<br />
FEATURE(masquerade_envelope)dnl<br />
FEATURE(masquerade_entire_domain)dnl</p>
<p>Si se desea cargar listas negras para resolver los problemas de Spam, pueden    añadirse las siguientes líneas justo arriba de MAILER(smtp)dnl:</p>
<p>FEATURE(dnsbl, `blackholes.mail-abuse.org&#8217;, `Rejected &#8211; see www.mail-abuse.org/rbl/&#8217;)dnl<br />
FEATURE(dnsbl, `dialups.mail-abuse.org&#8217;, `Rejected &#8211; see www.mail-abuse.org/dul/&#8217;)dnl<br />
FEATURE(dnsbl, `relays.mail-abuse.org&#8217;, `Rejected &#8211; see work-rss.mail-abuse.org/rss/&#8217;)dnl<br />
FEATURE(dnsbl, `sbl-xbl.spamhaus.org&#8217;, `Rejected &#8211; see http://www.spamhaus.org/SBL/&#8217;)dnl<br />
FEATURE(dnsbl, `bl.spamcop.net&#8217;, `Rejected &#8211; see http://spamcop.net/&#8217;)dnl</p>
<p>Una vez guardado este archivo ejecutaremos el siguiente comando:</p>
<p>makemap hash /etc/mail/access.db &lt; /etc/mail/access</p>
<p><strong>Archivo de configuración básica sendmail.mc</strong><br />
divert(-1)dnl<br />
dnl #<br />
dnl # This is the sendmail macro config file for m4. If you make changes to<br />
dnl # /etc/mail/sendmail.mc, you will need to regenerate the<br />
dnl # /etc/mail/sendmail.cf file by confirming that the sendmail-cf package    is<br />
dnl # installed and then performing a<br />
dnl #<br />
dnl # make -C /etc/mail<br />
dnl #<br />
include(`/usr/share/sendmail-cf/m4/cf.m4&#8242;)dnl<br />
VERSIONID(`setup for Red Hat Linux&#8217;)dnl<br />
OSTYPE(`linux&#8217;)dnl<br />
dnl #<br />
dnl # Uncomment and edit the following line if your outgoing mail needs to<br />
dnl # be sent out through an external mail server:<br />
dnl #<br />
dnl define(`SMART_HOST&#8217;,`smtp.your.provider&#8217;)<br />
dnl #<br />
define(`confDEF_USER_ID&#8217;,&#8220;8:12&#8221;)dnl<br />
define(`confTRUSTED_USER&#8217;, `smmsp&#8217;)dnl<br />
dnl define(`confAUTO_REBUILD&#8217;)dnl<br />
define(`confTO_CONNECT&#8217;, `1m&#8217;)dnl<br />
define(`confTRY_NULL_MX_LIST&#8217;,true)dnl<br />
define(`confDONT_PROBE_INTERFACES&#8217;,true)dnl<br />
define(`PROCMAIL_MAILER_PATH&#8217;,`/usr/bin/procmail&#8217;)dnl<br />
define(`ALIAS_FILE&#8217;, `/etc/aliases&#8217;)dnl<br />
dnl define(`STATUS_FILE&#8217;, `/etc/mail/statistics&#8217;)dnl<br />
define(`UUCP_MAILER_MAX&#8217;, `2000000&#8242;)dnl<br />
define(`confUSERDB_SPEC&#8217;, `/etc/mail/userdb.db&#8217;)dnl<br />
define(`confPRIVACY_FLAGS&#8217;, `authwarnings,novrfy,noexpn,restrictqrun&#8217;)dnl<br />
define(`confAUTH_OPTIONS&#8217;, `A&#8217;)dnl<br />
dnl #<br />
dnl # The following allows relaying if the user authenticates, and disallows<br />
dnl # plaintext authentication (PLAIN/LOGIN) on non-TLS links<br />
dnl #<br />
dnl define(`confAUTH_OPTIONS&#8217;, `A p&#8217;)dnl<br />
dnl #<br />
dnl # PLAIN is the preferred plaintext authentication method and used by<br />
dnl # Mozilla Mail and Evolution, though Outlook Express and other MUAs do<br />
dnl # use LOGIN. Other mechanisms should be used if the connection is not<br />
dnl # guaranteed secure.<br />
dnl #<br />
dnl TRUST_AUTH_MECH(`EXTERNAL DIGEST-MD5 CRAM-MD5 LOGIN PLAIN&#8217;)dnl<br />
dnl define(`confAUTH_MECHANISMS&#8217;, `EXTERNAL GSSAPI DIGEST-MD5 CRAM-MD5 LOGIN    PLAIN&#8217;)dnl<br />
dnl #<br />
dnl # Rudimentary information on creating certificates for sendmail TLS:<br />
dnl # make -C /usr/share/ssl/certs usage<br />
dnl #<br />
dnl define(`confCACERT_PATH&#8217;,`/usr/share/ssl/certs&#8217;)<br />
dnl define(`confCACERT&#8217;,`/usr/share/ssl/certs/ca-bundle.crt&#8217;)<br />
dnl define(`confSERVER_CERT&#8217;,`/usr/share/ssl/certs/sendmail.pem&#8217;)<br />
dnl define(`confSERVER_KEY&#8217;,`/usr/share/ssl/certs/sendmail.pem&#8217;)<br />
dnl #<br />
dnl # This allows sendmail to use a keyfile that is shared with OpenLDAP&#8217;s<br />
dnl # slapd, which requires the file to be readble by group ldap<br />
dnl #<br />
dnl define(`confDONT_BLAME_SENDMAIL&#8217;,`groupreadablekeyfile&#8217;)dnl<br />
dnl #<br />
dnl define(`confTO_QUEUEWARN&#8217;, `4h&#8217;)dnl<br />
dnl define(`confTO_QUEUERETURN&#8217;, `5d&#8217;)dnl<br />
dnl define(`confQUEUE_LA&#8217;, `12&#8242;)dnl<br />
dnl define(`confREFUSE_LA&#8217;, `18&#8242;)dnl<br />
define(`confTO_IDENT&#8217;, `0&#8242;)dnl<br />
dnl FEATURE(delay_checks)dnl<br />
FEATURE(`no_default_msa&#8217;,`dnl&#8217;)dnl<br />
FEATURE(`smrsh&#8217;,`/usr/sbin/smrsh&#8217;)dnl<br />
FEATURE(`mailertable&#8217;,`hash -o /etc/mail/mailertable.db&#8217;)dnl<br />
FEATURE(`virtusertable&#8217;,`hash -o /etc/mail/virtusertable.db&#8217;)dnl<br />
FEATURE(redirect)dnl<br />
FEATURE(always_add_domain)dnl<br />
FEATURE(use_cw_file)dnl<br />
FEATURE(use_ct_file)dnl<br />
dnl #<br />
dnl # The -t option will retry delivery if e.g. the user runs over his quota.<br />
dnl #<br />
FEATURE(local_procmail,`&#8217;,`procmail -t -Y -a $h -d $u&#8217;)dnl<br />
FEATURE(`access_db&#8217;,`hash -T -o /etc/mail/access.db&#8217;)dnl<br />
FEATURE(`blacklist_recipients&#8217;)dnl<br />
EXPOSED_USER(`root&#8217;)dnl<br />
dnl #<br />
dnl # The following causes sendmail to only listen on the IPv4 loopback address<br />
dnl # 127.0.0.1 and not on any other network devices. Remove the loopback<br />
dnl # address restriction to accept email from the internet or intranet.<br />
dnl #<br />
dnl DAEMON_OPTIONS(`Port=smtp,Addr=127.0.0.1, Name=MTA&#8217;)dnl<br />
dnl #<br />
dnl # The following causes sendmail to additionally listen to port 587 for<br />
dnl # mail from MUAs that authenticate. Roaming users who can&#8217;t reach their<br />
dnl # preferred sendmail daemon due to port 25 being blocked or redirected find<br />
dnl # this useful.<br />
dnl #<br />
dnl DAEMON_OPTIONS(`Port=submission, Name=MSA, M=Ea&#8217;)dnl<br />
dnl #<br />
dnl # The following causes sendmail to additionally listen to port 465, but<br />
dnl # starting immediately in TLS mode upon connecting. Port 25 or 587 followed<br />
dnl # by STARTTLS is preferred, but roaming clients using Outlook Express can&#8217;t<br />
dnl # do STARTTLS on ports other than 25. Mozilla Mail can ONLY use STARTTLS<br />
dnl # and doesn&#8217;t support the deprecated smtps; Evolution &lt;1.1.1 uses smtps<br />
dnl # when SSL is enabled&#8211; STARTTLS support is available in version 1.1.1.<br />
dnl #<br />
dnl # For this to work your OpenSSL certificates must be configured.<br />
dnl #<br />
dnl DAEMON_OPTIONS(`Port=smtps, Name=TLSMTA, M=s&#8217;)dnl<br />
dnl #<br />
dnl # The following causes sendmail to additionally listen on the IPv6 loopback<br />
dnl # device. Remove the loopback address restriction listen to the network.<br />
dnl #<br />
dnl # NOTE: binding both IPv4 and IPv6 daemon to the same port requires<br />
dnl # a kernel patch<br />
dnl #<br />
dnl DAEMON_OPTIONS(`port=smtp,Addr=::1, Name=MTA-v6, Family=inet6&#8242;)dnl<br />
dnl #<br />
dnl # We strongly recommend not accepting unresolvable domains if you want to<br />
dnl # protect yourself from spam. However, the laptop and users on computers<br />
dnl # that do not have 24&#215;7 DNS do need this.<br />
dnl #<br />
dnl FEATURE(`accept_unresolvable_domains&#8217;)dnl<br />
dnl #<br />
dnl FEATURE(`relay_based_on_MX&#8217;)dnl<br />
dnl #<br />
dnl # Also accept email sent to &#8220;localhost.localdomain&#8221; as local email.<br />
dnl #<br />
LOCAL_DOMAIN(`localhost.localdomain&#8217;)dnl<br />
dnl #<br />
dnl # The following example makes mail from this host and any additional<br />
dnl # specified domains appear to be sent from mydomain.com<br />
dnl #<br />
MASQUERADE_AS(`mi-dominio.org.mx&#8217;)dnl<br />
dnl #<br />
dnl # masquerade not just the headers, but the envelope as well<br />
dnl #<br />
FEATURE(masquerade_envelope)dnl<br />
dnl #<br />
dnl # masquerade not just @mydomainalias.com, but @*.mydomainalias.com as well<br />
dnl #<br />
dnl FEATURE(masquerade_entire_domain)dnl<br />
dnl #<br />
dnl MASQUERADE_DOMAIN(localhost)dnl<br />
dnl MASQUERADE_DOMAIN(localhost.localdomain)dnl<br />
dnl MASQUERADE_DOMAIN(mydomainalias.com)dnl<br />
dnl MASQUERADE_DOMAIN(mydomain.lan)dnl<br />
FEATURE(dnsbl, `blackholes.mail-abuse.org&#8217;, `Rejected &#8211; see www.mail-abuse.org/rbl/&#8217;)dnl<br />
FEATURE(dnsbl, `dialups.mail-abuse.org&#8217;, `Rejected &#8211; see www.mail-abuse.org/dul/&#8217;)dnl<br />
FEATURE(dnsbl, `relays.mail-abuse.org&#8217;, `Rejected &#8211; see work-rss.mail-abuse.org/rss/&#8217;)dnl<br />
FEATURE(`delay_checks&#8217;)dnl<br />
MAILER(smtp)dnl<br />
MAILER(procmail)dnl</p>
<p>Al final de este archivo justo después de &lt;b&gt;MAILER(procmail)dnl&lt;/b&gt;    añadiremos de la siguiente forma nuestros dominios:<br />
Cwdominio1.com<br />
Cwdominio2.com<br />
<strong>/**************************</strong><br />
Es decir Cw seguido del dominio <strong>*</strong><br />
<strong>**************************/</strong></p>
<p>Después de haber guardado este archivo generaremos el sendmail.cf con    el siguiente comando:<br />
m4 /etc/mail/sendmail.mc &gt; /etc/mail/sendmail.cf<br />
Ya casi estamos terminando, así que ahora una serie de comandos que ejecutaremos    en nuestra consola para rematar la faena:<br />
<strong>/sbin/newaliases</strong> &lt;- Para que nos pille la nueva configuración    de alias<br />
<strong>/sbin/service sendmail restart</strong> &lt;- Reiniciamos el servidor    Sendmail para que utilice nuestra nueva configuración<br />
<strong>/sbin/chkconfig &#8211;level 345 sendmail on</strong>&lt;- Para que Sendmail    se inicie con el sistema<br />
<strong>/sbin/iptables -t filter -A INPUT -p tcp -s 0/0 -d 0/0 &#8211;dport 25 -j    ACCEPT</strong>&lt;- Para aceptar el correo que nos envíen, sino tendriamos    un grave problema <img src='http://www.boscolopez.com/wp-includes/images/smilies/icon_razz.gif' alt=':P' class='wp-smiley' />  , podríamos enviar pero no recibir.<br />
<strong>Habilitamos los servicios pop e imap:</strong><br />
/sbin/chkconfig ipop3 on<br />
/sbin/chkconfig pop3s on<br />
/sbin/chkconfig imap on<br />
/sbin/chkconfig imaps on<br />
Reiniciamos el daemon xinetd:<br />
<strong>/sbin/service xinet restart</strong><br />
<strong>El Archivo Virtusertable</strong></p>
<p>Como dije al principio siempre nos puede ocurrir el tener que dar de alta a    dos usuarios con el mismo login pero en diferente dominio, lógicamente    es algo engorroso, pero si adoptamos el dar de alta a usuarios de la forma <strong>usuario1,    usuario2,..etc</strong> o bien de la forma <strong>usermail1,usermail2,&#8230;</strong> la que se os ocurra nos libraremos de estos problemas ya que en el archivo <strong>virtusertable</strong> podemos definir a que usuario está destinada cada cuenta de correo:</p>
<p>Pongamos un ejemplo de un archivo virtusertable:</p>
<p>pepito@dominio1.com usuario1<br />
pepito@dominio2.com usuario2<br />
admin@dominio1.com usuario3<br />
webmaster@dominio2.com usuario4<br />
&#8230;..</p>
<p>Una vez guardado este archivo ejecutamos el comando <strong> makemap hash /etc/mail/virtusertable.db    &lt; /etc/mail/virtusertable</strong> y reinciamos nuestro servidor de Sendmail.</p>
<p>Esto es todo por hoy, mañana más.</td>
</tr>
</tbody>
</table>
]]></content:encoded>
			<wfw:commentRss>http://www.boscolopez.com/?feed=rss2&amp;p=344</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Aplicaciones Backtrack 4 en Debian Lenny</title>
		<link>http://www.boscolopez.com/?p=341</link>
		<comments>http://www.boscolopez.com/?p=341#comments</comments>
		<pubDate>Sat, 17 Jul 2010 17:53:51 +0000</pubDate>
		<dc:creator>Bosco López</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Seguridad]]></category>

		<guid isPermaLink="false">http://www.boscolopez.com/?p=341</guid>
		<description><![CDATA[Por todas las mentes inquietas es conocida esta Live CD como la mejor para realizar auditorías de seguridad ya que posee un repositorio completísimo de aplicativos, scripts y etc.. El exagerado precio de los cd&#8217;s, dvd&#8217;s y cia, ha provocado que desde hace mucho tiempo no adquiera este tipo de medios, pero si que estaba [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.boscolopez.com/wp-content/uploads/2010/07/04.png"><img class="alignleft size-medium wp-image-342" title="Backtrack 4" src="http://www.boscolopez.com/wp-content/uploads/2010/07/04-300x225.png" alt="Backtrack 4" width="300" height="225" /></a>Por todas las mentes inquietas es conocida esta Live CD como la mejor para realizar auditorías de seguridad ya que posee un repositorio completísimo de aplicativos, scripts y etc..</p>
<p>El exagerado precio de los cd&#8217;s, dvd&#8217;s y cia, ha provocado que desde hace mucho tiempo no adquiera este tipo de medios, pero si que estaba interesado en tener la Backtrack 4 o almenos algunos aplicativos de ella para realizar ciertas pruebas.</p>
<p>En mi Asus X20 tengo una Debian Lenny y tampoco quería quitarla para poner la Backtrack, así que investigué si había alguna forma de agregar los repositorios de Backtrack a mi Debian Lenny y así poderme permitir el instalar esos aplicativos.</p>
<p>El resultado ha sido positivo.</p>
<p>Lo primero de todo es agregar el certificado PGP:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">wget</span> <span style="color: #660033;">-q</span> http:<span style="color: #000000; font-weight: bold;">//</span>archive.offensive-security.com<span style="color: #000000; font-weight: bold;">/</span>backtrack.gpg <span style="color: #660033;">-O-</span> <span style="color: #000000; font-weight: bold;">|</span> <span style="color: #c20cb9; font-weight: bold;">sudo</span> <span style="color: #c20cb9; font-weight: bold;">apt-key</span> add -</pre></div></div>

<p>Ahora añadiremos el repositorio:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">sudo</span> <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;deb http://archive.offensive-security.com pwnsauce main microverse macroverse restricted universe multiverse&quot;</span> <span style="color: #000000; font-weight: bold;">&amp;</span>gt; <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>apt<span style="color: #000000; font-weight: bold;">/</span>sources.list</pre></div></div>

<p>Tras esto ya tengo funcionando distintos aplicativos que vienen con la Backtrack, a medida que vaya mejorando las cosillas os lo comento <img src='http://www.boscolopez.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://www.boscolopez.com/?feed=rss2&amp;p=341</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Script taréas de mantenimiento</title>
		<link>http://www.boscolopez.com/?p=332</link>
		<comments>http://www.boscolopez.com/?p=332#comments</comments>
		<pubDate>Thu, 15 Jul 2010 21:46:25 +0000</pubDate>
		<dc:creator>Bosco López</dc:creator>
				<category><![CDATA[Scripting]]></category>
		<category><![CDATA[Windows]]></category>

		<guid isPermaLink="false">http://www.boscolopez.com/?p=332</guid>
		<description><![CDATA[En una red corporativa de bastantes pc&#8217;s realizar tareas de mantenimiento de los equipos, es algo tedioso, y los usuarios no siempre permiten que les utilices su equipo, así que se me ocurrió el generar un script que realizara las tareas de mantenimiento y añadirlo al script de cierre de sesión. Lo primero que hice [...]]]></description>
			<content:encoded><![CDATA[<p>En una red corpor<img class="alignleft" title="Consola" src="http://www.boscolopez.com/wp-content/uploads/2010/01/consola-150x150.jpg" alt="" width="150" height="150" />ativa de bastantes pc&#8217;s realizar tareas de mantenimiento de los equipos, es algo tedioso, y los usuarios no siempre permiten que les utilices su equipo, así que se me ocurrió el generar un script que realizara las tareas de mantenimiento y añadirlo al script de cierre de sesión.</p>
<p>Lo primero que hice fue generar desde el login script en la unidad C: un directorio llamado <em><strong>mant</strong></em>, a este directorio les copie un ccleaner portable, ntregopt y pagedfrg.</p>
<p>Una vez echo esto cree un subdirectorio dentro del de logs en el servidor, llamado mantenimiento, para que se guardara el registro de las operaciones realizadas y así después revisarlo con calma.</p>

<div class="wp_syntax"><div class="code"><pre class="dos" style="font-family:monospace;"><span style="color: #33cc33;">@</span><span style="color: #b1b100; font-weight: bold;">echo</span> off
<span style="color: #b1b100; font-weight: bold;">echo</span> --------------------------------------
<span style="color: #b1b100; font-weight: bold;">echo</span> Script de mantenimiento de equipos
<span style="color: #b1b100; font-weight: bold;">echo</span> Bosco Lopez
<span style="color: #b1b100; font-weight: bold;">echo</span> --------------------------------------
<span style="color: #b1b100; font-weight: bold;">set</span> <span style="color: #448844;">servidor</span>=
<span style="color: #b1b100; font-weight: bold;">cd</span> &quot;c:\mant&quot;
<span style="color: #b1b100; font-weight: bold;">echo</span> Ejecutamos CCleaner
<span style="color: #b1b100; font-weight: bold;">echo</span> ...
ccleaner.exe /auto
<span style="color: #b1b100; font-weight: bold;">echo</span> Ejecutamos CHKDSK
CHKDSK
<span style="color: #b1b100; font-weight: bold;">echo</span> CHKDSK finalizado
<span style="color: #b1b100; font-weight: bold;">echo</span> Ejecutamos Defrag
defrag c: -f &gt; k:\<span style="color: #33cc33;">%</span><span style="color: #448888;">hostname</span><span style="color: #33cc33;">%</span>.txt
<span style="color: #b1b100; font-weight: bold;">echo</span> Ejecutamos Pagedefrag
pagedfrg.exe -o
<span style="color: #b1b100; font-weight: bold;">echo</span> Ejecutamos NTREG y reiniciamos
ntregopt.exe silent /reboot</pre></div></div>

<p>Espero que os sirva <img src='http://www.boscolopez.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://www.boscolopez.com/?feed=rss2&amp;p=332</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Comandos utilizando Escritorio Remoto (RDP)</title>
		<link>http://www.boscolopez.com/?p=333</link>
		<comments>http://www.boscolopez.com/?p=333#comments</comments>
		<pubDate>Thu, 15 Jul 2010 21:29:46 +0000</pubDate>
		<dc:creator>Bosco López</dc:creator>
				<category><![CDATA[Windows]]></category>

		<guid isPermaLink="false">http://www.boscolopez.com/?p=333</guid>
		<description><![CDATA[Hace ya un tiempo que estoy utilizando la última versión del cliente de Escritorio Remoto de Windows, el cual, trae algunas novedades interesantes que os paso a listar: Web Single sign-on (SSO) y formularios web de autentificación. Acceso a escritorios virtuales utilizando RD Connection Broker. Estado de conexión en el system tray Redirección del reproductor [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.boscolopez.com/wp-content/uploads/2010/07/image.png"><img class="alignleft size-medium wp-image-334" title="Escritorio Remote RDP" src="http://www.boscolopez.com/wp-content/uploads/2010/07/image-300x189.png" alt="" width="300" height="189" /></a> Hace ya un tiempo que estoy utilizando la última versión del cliente de Escritorio Remoto de Windows, el cual, trae algunas novedades interesantes que os paso a listar:</p>
<ol>
<li>Web Single sign-on (SSO) y formularios web de autentificación.</li>
<li>Acceso a escritorios virtuales utilizando RD Connection Broker.</li>
<li>Estado de conexión en el system tray</li>
<li>Redirección del reproductor Windows Media Player</li>
<li>Audio bidireccional</li>
<li>Soporte de múltiples monitores</li>
<li>Remote APP</li>
<li>Soporte Aero Glass</li>
</ol>
<p>Pero bueno ese no es el tema a tratar, aunque os aconsejo probarlo.</p>
<p>Para mí lo fundamental cuando estás hablando con alguien que supuestamente se dedica a la administración de sistemas es que almenos conozca los comandos del sistema o los aplicativos que utiliza; y no tener que escuchar&#8230;&#8221;Instalamos X aplicativo por que con este no se puede hacer &#8230;&#8221;</p>
<p>Pues bien voy a poner unos comandos básicos para utilizar con RDP y que considero que alguno se quedará sorprendido por que ni los conocía.</p>
<ul>
<li><strong>CTRL + ALT + END: </strong>Abre el diálogo de seguridad de Windows o lo que es lo mismo sustituye al CTRL + ALT + SUPR</li>
<li><strong>ALT + PAGE UP: </strong>Cambia entre appz de izquierda a derecha</li>
<li><strong>ALG + PAGE DOWN: </strong>Cambia entre appz de derecha a izquierda</li>
<li><strong>ALT + INSERT: </strong>Sustituye a ALT + TAB</li>
<li><strong>ALT + HOME: </strong>Muestra el menú de inicio</li>
<li><strong>CTRL + ALT + BREAK: </strong>Pasa a pantalla completa</li>
<li><strong>ALT + DELETE: </strong>Muestra el menú</li>
<li><strong>CTRL + ALT + -: </strong>Captura de pantalla al igual que ALT + Print Screen</li>
<li><strong>CTRL + ALT + +: </strong>Captura pantalla al igual que Print Screen</li>
</ul>
<p>Bueno ahora&#8230; creo que es el momento de despedirse.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.boscolopez.com/?feed=rss2&amp;p=333</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Como instalar Nagios en Solaris</title>
		<link>http://www.boscolopez.com/?p=316</link>
		<comments>http://www.boscolopez.com/?p=316#comments</comments>
		<pubDate>Mon, 05 Jul 2010 19:38:19 +0000</pubDate>
		<dc:creator>Bosco López</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[How-to]]></category>
		<category><![CDATA[monitorizacion]]></category>
		<category><![CDATA[Nagios]]></category>

		<guid isPermaLink="false">http://www.boscolopez.com/?p=316</guid>
		<description><![CDATA[Hace ya más de un año hice un manual de como instalar Nagios en Solaris para la empresa y creo que es un buen HOW-TO para compartir. Se trata en un paso a paso de Como instalar un servidor de Monitorización con Nagios. Que de todos los sistemas de monitorización que he probado me parece [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.boscolopez.com/wp-content/uploads/2010/07/nagiospowered-72x72.png"><img class="alignleft size-full wp-image-318" title="Nagios" src="http://www.boscolopez.com/wp-content/uploads/2010/07/nagiospowered-72x72.png" alt="Nagios" width="72" height="72" /></a> Hace ya más de un año hice un manual de como instalar Nagios en Solaris para la empresa y creo que es un buen HOW-TO para compartir.</p>
<p>Se trata en un paso a paso de Como instalar un servidor de Monitorización con Nagios. Que de todos los sistemas de monitorización que he probado me parece el más completo, es cierto que hay que hacerse mucho script para tener las funcionalidades que tienen algunos como el autodiscover y etc&#8230;, pero la comunidad me parece muy amplia y por lo de ahora he encontrado siempre la forma de hacer lo que he querido.</p>
<p>Si estáis pensando en montar un sistema de monitorización os recomendaría este.</p>
<p style="text-align: left;"><strong>Tabla de contenidos</strong></p>
<p style="text-align: left;">1. Requerimientos del sistema<br />
2. Instalando Nagios<br />
3. Configurando Nagios<br />
4. Verificación de la configuración de Nagios<br />
5. Instalando cliente en un sistema Linux / Unix<br />
6. Instalando cliente en sistemas Windows<br />
7. Monitorizar routers/switches<br />
8. Monitorizar impresoras de red<br />
9. Monitorizar servicios públicos</p>
<p><strong>1.Requerimientos del sistema</strong><br />
Los requerimientos del sistema aquí descritos serán para la máquina que ejercerá las funciones de<br />
servidor de monitorización; la cual deberá tener un sistema Linux o alguna variante de Unix y un<br />
compilador de C correctamente instalado. Esto último es obvio, pero no será la primera vez que nos<br />
encontremos una máquina sin el.<br />
El servidor tendrá que tener correctamente instalado y configurado un servidor web,<br />
preferiblemente Apache y las librerías GD versión 1.6.3 o superior; las cuales son requeridas para la<br />
utilización de la función statusmap; esto lo podemos verificar con el comando: pkginfo<br />
En el caso de servidores bajo Solaris, es posible que tengamos que tengamos que retocar una serie<br />
de parámetros antes de poder comenzar la instalación.<br />
<em><strong>1. Tener acceso a la cuenta root o en su defecto que esté instalado sudo</strong></em><br />
<em><strong>2. Preparar el entorno solaris para un correcto funcionamiento:</strong></em><br />
<em><strong>1. Modificar la shell por defecto a Bash</strong></em></p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">$ usermod <span style="color: #660033;">-s</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>bin<span style="color: #000000; font-weight: bold;">/</span><span style="color: #c20cb9; font-weight: bold;">bash</span></pre></div></div>

<p><em><strong>2. Corregir el Path</strong></em></p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">$ <span style="color: #7a0874; font-weight: bold;">export</span> <span style="color: #007800;">PATH</span>=<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>sfw<span style="color: #000000; font-weight: bold;">/</span>bin:<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>ccs<span style="color: #000000; font-weight: bold;">/</span>bin:<span style="color: #000000; font-weight: bold;">/</span>opt<span style="color: #000000; font-weight: bold;">/</span>sfw<span style="color: #000000; font-weight: bold;">/</span>bin<span style="color: #000000; font-weight: bold;">/</span>:<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>bin:<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>ucb:<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>sbin</pre></div></div>

<p><em><strong>3. Modificar las opciones de compilación.</strong></em></p>
<p>Esto es opcional, no tendríamos por que realizarlo, pero con las pruebas que he realizado haremos que Nagios trabaje mucho más<br />
rápido dentro de nuestro sistema, modificando -mcpu y -mtune a “ultrasparc”, siempre<br />
y cuando el sistema sobre el que estemos operando esté basado en Solaric SPARC. Esto<br />
nos lo debe especificar el cliente.</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">$ <span style="color: #7a0874; font-weight: bold;">export</span> <span style="color: #007800;">CFLAGS</span>=”-03 <span style="color: #660033;">-pipe</span> <span style="color: #660033;">-mcpu</span>=ultrasparc <span style="color: #660033;">-mtune</span>=ultrasparc”</pre></div></div>

<p>4. Estos cambios que hemos realizado, podríamos permitir que el cliente siempre trabajara<br />
con ellos si nos lo solicitase. Para eso editaríamos el archivo .profile y lo dejaríamos de<br />
la siguiente manera:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #007800;">PATH</span>=<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>sfw<span style="color: #000000; font-weight: bold;">/</span>bin:<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>ccs<span style="color: #000000; font-weight: bold;">/</span>bin:<span style="color: #000000; font-weight: bold;">/</span>opt<span style="color: #000000; font-weight: bold;">/</span>sfw<span style="color: #000000; font-weight: bold;">/</span>bin<span style="color: #000000; font-weight: bold;">/</span>:<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>bin:<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>ucb:<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>sbin
<span style="color: #007800;">CFLAGS</span>=<span style="color: #ff0000;">&quot;-O3 -pipe -mcpu=ultrasparc -mtune=ultrasparc&quot;</span>
<span style="color: #7a0874; font-weight: bold;">export</span> PATH CFLAGS</pre></div></div>

<p><em><strong>5. Instalar las librerías GD en caso de que el cliente aun no las hubiese instalado.</strong></em></p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">$ <span style="color: #c20cb9; font-weight: bold;">gunzip</span> gd-2.0.35.tar.gz
$ <span style="color: #c20cb9; font-weight: bold;">tar</span> <span style="color: #660033;">-xvf</span> gd-2.0.35.tar
$ <span style="color: #7a0874; font-weight: bold;">cd</span> gd-2.0.35
$ .<span style="color: #000000; font-weight: bold;">/</span>configure
$ <span style="color: #c20cb9; font-weight: bold;">make</span>
$ <span style="color: #c20cb9; font-weight: bold;">make</span> <span style="color: #7a0874; font-weight: bold;">test</span>
$ <span style="color: #c20cb9; font-weight: bold;">make</span> <span style="color: #c20cb9; font-weight: bold;">install</span></pre></div></div>

<p><strong>2.Instalando Nagios</strong><br />
Antes de comenzar a instalar Nagios, precisamos dar de alta el usuario nagios y el grupo nagios<br />
para la aplicación lo cual realizaremos ejecutando los siguientes comandos:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">$ grouadd nagios
$ useradd <span style="color: #660033;">-d</span> <span style="color: #007800;">$NAGIOSHOME</span> <span style="color: #660033;">-g</span> nagios <span style="color: #660033;">-s</span> <span style="color: #000000; font-weight: bold;">/</span>bin<span style="color: #000000; font-weight: bold;">/</span><span style="color: #c20cb9; font-weight: bold;">false</span> <span style="color: #660033;">-m</span> nagios</pre></div></div>

<p>Una vez hemos descomprimido el paquete de nagios ejecutaremos el siguiente comando:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">$ .<span style="color: #000000; font-weight: bold;">/</span>configure –<span style="color: #007800;">prefix</span>=<span style="color: #007800;">$NAGIOSHOME</span> –with-nagios-user=nagios –with-nagios-grp=nagios
<span style="color: #660033;">--with-perlcache</span> –enable-embedded-perl –with-gd-inc=<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>include
<span style="color: #660033;">--with-gd-lib</span>=<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>lib</pre></div></div>

<p>Este comando si todos los pasos previos han sido correctos, no nos debería mostrar ningún tipo de<br />
error así que podríamos ejecutar los siguientes:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">$ <span style="color: #c20cb9; font-weight: bold;">make</span> all
$ <span style="color: #c20cb9; font-weight: bold;">make</span> <span style="color: #c20cb9; font-weight: bold;">install</span>
$ <span style="color: #c20cb9; font-weight: bold;">make</span> install-config
$ <span style="color: #c20cb9; font-weight: bold;">make</span> install-init</pre></div></div>

<p>Si el cliente nos solicita que se instale con mysql o postgree ejecutaríamos lo siguiente:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">$ .<span style="color: #000000; font-weight: bold;">/</span>configure –<span style="color: #007800;">prefix</span>=<span style="color: #007800;">$NAGIOSHOME</span> –with-mysql=<span style="color: #000000; font-weight: bold;">&amp;</span>lt;ruta mysql<span style="color: #000000; font-weight: bold;">&amp;</span>gt; ó –with-pgsql=<span style="color: #000000; font-weight: bold;">&amp;</span>lt;ruta pgsql<span style="color: #000000; font-weight: bold;">&amp;</span>gt;
$ <span style="color: #c20cb9; font-weight: bold;">make</span>
$ <span style="color: #c20cb9; font-weight: bold;">make</span> <span style="color: #c20cb9; font-weight: bold;">install</span>
$ <span style="color: #7a0874; font-weight: bold;">cd</span> <span style="color: #007800;">$NAGIOSHOME</span>
$ <span style="color: #c20cb9; font-weight: bold;">chown</span> <span style="color: #660033;">-R</span> nagios:nagios libexec
$ <span style="color: #c20cb9; font-weight: bold;">chown</span> <span style="color: #660033;">-R</span> nagios:nagios share</pre></div></div>

<p>Una vez echo el paso anterior, procederemos a instalar un plugin para nagios para eso ejecutaremos<br />
los siguientes comandos:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">$ <span style="color: #c20cb9; font-weight: bold;">gunzip</span> nagios-plugins-1.4.11.tar.gz
$ <span style="color: #c20cb9; font-weight: bold;">tar</span> <span style="color: #660033;">-xvf</span> nagios-plugins-1.4.11.tar
$ <span style="color: #7a0874; font-weight: bold;">cd</span> nagios-plugins-1.4.11
$ .<span style="color: #000000; font-weight: bold;">/</span>configure –with-nagios-user=nagios –with-nagios-group=nagios
$ <span style="color: #c20cb9; font-weight: bold;">make</span>
$ <span style="color: #c20cb9; font-weight: bold;">make</span> <span style="color: #c20cb9; font-weight: bold;">install</span></pre></div></div>

<p>Configuraremos que Nagios se ejecute automáticamente en caso de que el servidor se reinicie:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">$ <span style="color: #c20cb9; font-weight: bold;">ln</span> <span style="color: #660033;">-s</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>init.d<span style="color: #000000; font-weight: bold;">/</span>nagios <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>rcS.d<span style="color: #000000; font-weight: bold;">/</span>S99nagios
$ <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>nagios<span style="color: #000000; font-weight: bold;">/</span>bin<span style="color: #000000; font-weight: bold;">/</span>nagios <span style="color: #660033;">-v</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>nagios<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>nagios.cfg
$ <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>init.d<span style="color: #000000; font-weight: bold;">/</span>nagios start</pre></div></div>

<p>Ahora procederemos a instalar nrpe que es el agente y se puede redistribuir desde el servidor:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">$ <span style="color: #c20cb9; font-weight: bold;">gunzip</span> nrpe-1.9.tar.gz
$ <span style="color: #c20cb9; font-weight: bold;">tar</span> <span style="color: #660033;">-xvf</span> nrpe-1.9.tar.gz
$ <span style="color: #7a0874; font-weight: bold;">cd</span> nrpe-1.9.tar.gz
$ .<span style="color: #000000; font-weight: bold;">/</span>configure
$ <span style="color: #c20cb9; font-weight: bold;">make</span> all
$ <span style="color: #c20cb9; font-weight: bold;">cp</span> .<span style="color: #000000; font-weight: bold;">/</span>src<span style="color: #000000; font-weight: bold;">/</span>nrpe <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>nagios
$ <span style="color: #c20cb9; font-weight: bold;">cp</span> .<span style="color: #000000; font-weight: bold;">/</span>src<span style="color: #000000; font-weight: bold;">/</span>check_nrpe <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>nagios
$ <span style="color: #c20cb9; font-weight: bold;">cp</span> nrpe.cfg <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>nagios
$ <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span><span style="color: #7a0874; font-weight: bold;">local</span>
$ <span style="color: #c20cb9; font-weight: bold;">chown</span> <span style="color: #660033;">-R</span> nagios:nagios nagios</pre></div></div>

<p>Procederemos a editar /etc/services y añadiremos la siguiente línea:<br />
nrpe 5666/tcp #nrpe, servicio de monitorización nagios<br />
Añadiremos en /etc/xinetd.d el archivo nrpe con lo siguiente:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #666666; font-style: italic;"># default: on</span>
<span style="color: #666666; font-style: italic;"># description: NRPE</span>
service nrpe
<span style="color: #7a0874; font-weight: bold;">&#123;</span>
<span style="color: #c20cb9; font-weight: bold;">id</span> = nrpe
socket_type = stream
protocol = tcp
user = nagios
<span style="color: #c20cb9; font-weight: bold;">groups</span> = <span style="color: #c20cb9; font-weight: bold;">yes</span>
<span style="color: #7a0874; font-weight: bold;">wait</span> = no
disable = no
server = <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>nagios<span style="color: #000000; font-weight: bold;">/</span>nrpe
server_args = <span style="color: #660033;">-c</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>nagios<span style="color: #000000; font-weight: bold;">/</span>nrpe.cfg <span style="color: #660033;">--inetd</span>
<span style="color: #7a0874; font-weight: bold;">&#125;</span></pre></div></div>

<p>Una vez realizado ejecutaremos:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">$ <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>init.d<span style="color: #000000; font-weight: bold;">/</span>xinetd restart
$ <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>nagios<span style="color: #000000; font-weight: bold;">/</span>nrpe <span style="color: #660033;">-c</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>nagios<span style="color: #000000; font-weight: bold;">/</span>nrpe.cfg –deamon</pre></div></div>

<p>Le haremos unos retoques al archivo /etc/init.d/nagios</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #666666; font-style: italic;">#!/sbin/sh</span>
<span style="color: #666666; font-style: italic;">#</span>
<span style="color: #666666; font-style: italic;"># /etc/init.d/nagios startup script</span>
<span style="color: #666666; font-style: italic;">#</span>
<span style="color: #000000; font-weight: bold;">case</span> <span style="color: #ff0000;">&quot;$1&quot;</span> <span style="color: #000000; font-weight: bold;">in</span>
start<span style="color: #7a0874; font-weight: bold;">&#41;</span>
<span style="color: #7a0874; font-weight: bold;">&#91;</span> <span style="color: #660033;">-f</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>nagios<span style="color: #000000; font-weight: bold;">/</span>nrpe.cfg <span style="color: #7a0874; font-weight: bold;">&#93;</span> <span style="color: #000000; font-weight: bold;">||</span> <span style="color: #7a0874; font-weight: bold;">exit</span> <span style="color: #000000;">0</span>
<span style="color: #666666; font-style: italic;"># start nagios</span>
<span style="color: #7a0874; font-weight: bold;">cd</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>nagios
.<span style="color: #000000; font-weight: bold;">/</span>nrpe <span style="color: #660033;">-c</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>nagios<span style="color: #000000; font-weight: bold;">/</span>nrpe.cfg <span style="color: #660033;">--daemon</span>
<span style="color: #000000; font-weight: bold;">;;</span>
stop<span style="color: #7a0874; font-weight: bold;">&#41;</span>
<span style="color: #666666; font-style: italic;"># stop nagios</span>
<span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;use ps to kill nrpe&quot;</span>
<span style="color: #000000; font-weight: bold;">;;</span>
<span style="color: #000000; font-weight: bold;">*</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>
<span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;Usage: $0 { start | stop }&quot;</span>
<span style="color: #7a0874; font-weight: bold;">exit</span> <span style="color: #000000;">1</span>
<span style="color: #000000; font-weight: bold;">;;</span>
<span style="color: #000000; font-weight: bold;">esac</span>
<span style="color: #7a0874; font-weight: bold;">exit</span> <span style="color: #000000;">0</span></pre></div></div>

<p><strong>3. Configurando Nagios</strong><br />
Ahora que tenemos Nagios instalado, tendremos que configurar una serie de archivos, ya que por<br />
defecto no nos cargará ningún archivo de configuración, pero la configuración por defecto para<br />
comenzar e ir configurando poco a poco con el cliente nos servirá para tener una base.<br />
Los archivos de configuración de ejemplo los tenemos en $NAGIOSHOME/etc/*.cfg-sample y los<br />
copiaríamos a $NAGIOSHOME/etc/*.cfg</p>
<p>Para renombrar estos archivos utilizaríamos el comando mv, quedandonos el siguiente listado:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #007800;">cfg_file</span>=<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>nagios<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>contactgroups.cfg
<span style="color: #007800;">cfg_file</span>=<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>nagios<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>contacts.cfg
<span style="color: #007800;">cfg_file</span>=<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>nagios<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>dependencies.cfg
<span style="color: #007800;">cfg_file</span>=<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>nagios<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>escalations.cfg
<span style="color: #007800;">cfg_file</span>=<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>nagios<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>hostgroups.cfg
<span style="color: #007800;">cfg_file</span>=<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>nagios<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>hosts.cfg
<span style="color: #007800;">cfg_file</span>=<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>nagios<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>servicegroups.cfg
<span style="color: #007800;">cfg_file</span>=<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>nagios<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>disk_services.cfg
<span style="color: #007800;">cfg_file</span>=<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>nagios<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>database_services.cfg
<span style="color: #007800;">cfg_file</span>=<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>nagios<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>web_services.cfg
<span style="color: #007800;">cfg_file</span>=<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>nagios<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>local_services.cfg
<span style="color: #007800;">cfg_file</span>=<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>nagios<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>timeperiods.cfg
<span style="color: #007800;">cfg_file</span>=<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>nagios<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>windows-services.cfg</pre></div></div>

<p>El archivo primordial que debemos editar es contacts.cfg, y designaremos al e-mail que deseamos<br />
que nos lleguen las alertas; para eso utilizaremos el siguiente comando:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">$ <span style="color: #c20cb9; font-weight: bold;">vi</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>nagios<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>contacts.cfg</pre></div></div>

<p><strong>Algunos comandos sobre Vi</strong><em><br />
<strong>Borrar carácter actual</strong> x<br />
<strong>Borrar carácter anterior</strong> X<br />
<strong>Borrar palabra</strong> dw<br />
<strong>Guardar archivo</strong> <img src='http://www.boscolopez.com/wp-includes/images/smilies/icon_mad.gif' alt=':x' class='wp-smiley' /><br />
<strong>Salir sin guardar</strong> :q!</em><br />
Recordar que la tecla borrar en Vi no ejerce sus funciones al igual que tampoco supr.</p>
<p>Un ejemplo de contacto sería el siguiente:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #666666; font-style: italic;"># 'general' contact definition</span>
define contact<span style="color: #7a0874; font-weight: bold;">&#123;</span>
contact_name general
<span style="color: #7a0874; font-weight: bold;">alias</span> general
service_notification_period workinghours
host_notification_period workinghours
service_notification_options u,c
host_notification_options d,u
service_notification_commands notify-by-email
host_notification_commands host-notify-by-email
email usuario<span style="color: #000000; font-weight: bold;">@</span>dominio.ext
<span style="color: #7a0874; font-weight: bold;">&#125;</span>
<span style="color: #666666; font-style: italic;"># 'guardia' contact definition</span>
define contact<span style="color: #7a0874; font-weight: bold;">&#123;</span>
contact_name guardia
<span style="color: #7a0874; font-weight: bold;">alias</span> tecnico guardia
service_notification_period 24x7
host_notification_period 24x7
service_notification_options <span style="color: #c20cb9; font-weight: bold;">w</span>,u,c,r
host_notification_options d,u,r
service_notification_commands notify-by-email
host_notification_commands host-notify-by-email
email usuario<span style="color: #000000; font-weight: bold;">@</span>dominio.ext
<span style="color: #7a0874; font-weight: bold;">&#125;</span></pre></div></div>

<p>Los periodos de notificaciones también pueden ser editados:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #666666; font-style: italic;"># '24x7' timeperiod definition</span>
define timeperiod<span style="color: #7a0874; font-weight: bold;">&#123;</span>
timeperiod_name 24x7
<span style="color: #7a0874; font-weight: bold;">alias</span> <span style="color: #000000;">24</span> Horas al dia, <span style="color: #000000;">7</span> Dias a la semana
sunday 00:00-<span style="color: #000000;">24</span>:00
monday 00:00-<span style="color: #000000;">24</span>:00
tuesday 00:00-<span style="color: #000000;">24</span>:00
wednesday 00:00-<span style="color: #000000;">24</span>:00
thursday 00:00-<span style="color: #000000;">24</span>:00
friday 00:00-<span style="color: #000000;">24</span>:00
saturday 00:00-<span style="color: #000000;">24</span>:00
<span style="color: #7a0874; font-weight: bold;">&#125;</span></pre></div></div>

<p>Una vez editado este archivo ejecutaremos el siguiente comando:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">$ <span style="color: #c20cb9; font-weight: bold;">make</span> install-webconf</pre></div></div>

<p>Crearemos el usuario que nos solicite el cliente para identificarse vía web. Es importante que el<br />
cliente anote la contraseña que nos proporcionará para este usuario o que la memorice bien.</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">$ htpasswd <span style="color: #660033;">-c</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>nagios<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>htpasswd.users USUARIODELCLIENTE
$<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>init.d<span style="color: #000000; font-weight: bold;">/</span>apache2 reload</pre></div></div>

<p>Si queremos comprobar este último comando:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">$ <span style="color: #7a0874; font-weight: bold;">cd</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>init.d<span style="color: #000000; font-weight: bold;">/</span></pre></div></div>


<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">$ <span style="color: #c20cb9; font-weight: bold;">ls</span></pre></div></div>

<p> (nos listará los archivos y veremos uno que pone apache o apache2)<br />
Si pone apache ejecutaríamos:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">$ <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>init.d<span style="color: #000000; font-weight: bold;">/</span>apache reload</pre></div></div>

<p>Si pone apache2 ejecutaríamos:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">$<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>init.d<span style="color: #000000; font-weight: bold;">/</span>apache2 reload</pre></div></div>

<p>Una recomendación que se le puede realizar al cliente es que se implemente Digest, en caso de que<br />
acepte, ejecutaríamos el siguiente comando:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">$ htdigest <span style="color: #660033;">-c</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>nagios<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>.digest_pw “Nagios access” USUARIODELCLIENTE</pre></div></div>

<p>Una vez echo esto, tendríamos que editar el archivo de configuración que normalmente está en la<br />
ruta /etc/httpd/conf.d/nagios.conf y podríamos utilizar el siguiente ejemplo de configuración:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #666666; font-style: italic;">## BEGIN APACHE CONFIG SNIPPET - NAGIOS.CONF</span>
ScriptAlias <span style="color: #000000; font-weight: bold;">/</span>nagios<span style="color: #000000; font-weight: bold;">/</span>cgi-bin <span style="color: #ff0000;">&quot;/usr/local/nagios/sbin&quot;</span>
<span style="color: #000000; font-weight: bold;">&lt;</span>Directory <span style="color: #ff0000;">&quot;/usr/local/nagios/sbin&quot;</span><span style="color: #000000; font-weight: bold;">&gt;</span>
Options ExecCGI
AllowOverride None
Order allow,deny
Allow from all
AuthType Digest
AuthName <span style="color: #ff0000;">&quot;Nagios Access&quot;</span>
AuthUserFile <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>nagios<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>.digest_pw
Require valid-user
<span style="color: #000000; font-weight: bold;">&lt;/</span>Directory<span style="color: #000000; font-weight: bold;">&gt;</span>
Alias <span style="color: #000000; font-weight: bold;">/</span>nagios <span style="color: #ff0000;">&quot;/usr/local/nagios/share&quot;</span>
<span style="color: #000000; font-weight: bold;">&lt;</span>Directory <span style="color: #ff0000;">&quot;/usr/local/nagios/share&quot;</span><span style="color: #000000; font-weight: bold;">&amp;</span>gt<span style="color: #000000; font-weight: bold;">&gt;</span>
Options None
AllowOverride None
Order allow,deny
Allow from all
AuthType Digest
AuthName <span style="color: #ff0000;">&quot;Nagios Access&quot;</span>
AuthUserFile <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>nagios<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>.digest_pw
Require valid-user
<span style="color: #000000; font-weight: bold;">&lt;/</span>Directory<span style="color: #000000; font-weight: bold;">&gt;</span>
<span style="color: #666666; font-style: italic;">## END APACHE CONFIG SNIPPETS</span></pre></div></div>

<p>Una vez echo ejecutaríamos el comando anteriormente mencionado para reiniciar el servidor web:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">$ <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>init.d<span style="color: #000000; font-weight: bold;">/</span>apache2 restart</pre></div></div>

<p>Para un cliente con subredes, podría ser interesante la siguiente configuración que nos permite<br />
habilitar para que ip&#8217;s está permitido el acceso y para cuales no; esto también se realiza en el<br />
archivo nagios.conf que por defecto nos encontraremos en la ruta /etc/httpd/conf.d/nagios.conf</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #666666; font-style: italic;">## BEGIN APACHE CONFIG SNIPPET - NAGIOS.CONF</span>
ScriptAlias <span style="color: #000000; font-weight: bold;">/</span>nagios<span style="color: #000000; font-weight: bold;">/</span>cgi-bin <span style="color: #ff0000;">&quot;/usr/local/nagios/sbin&quot;</span>
<span style="color: #000000; font-weight: bold;">&lt;</span>Directory <span style="color: #ff0000;">&quot;/usr/local/nagios/sbin&quot;</span><span style="color: #000000; font-weight: bold;">&gt;</span></pre></div></div>

<p>&#8230;</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">AllowOverride None
Order deny,allow
Deny from all
Allow from 127.0.0.1 10.0.0.25 <span style="color: #666666; font-style: italic;"># Allow single IP addresses</span>
Allow from 10.0.0.0<span style="color: #000000; font-weight: bold;">/</span>255.255.255.0 <span style="color: #666666; font-style: italic;"># Allow network/netmask pair</span>
Allow from 10.0.0.0<span style="color: #000000; font-weight: bold;">/</span><span style="color: #000000;">24</span> <span style="color: #666666; font-style: italic;"># Allow network/nnn CIDR spec</span>
...
<span style="color: #000000; font-weight: bold;">&lt;/</span>Directory<span style="color: #000000; font-weight: bold;">&gt;</span>
Alias <span style="color: #000000; font-weight: bold;">/</span>nagios <span style="color: #ff0000;">&quot;/usr/local/nagios/share&quot;</span>
<span style="color: #000000; font-weight: bold;">&lt;</span>Directory <span style="color: #ff0000;">&quot;/usr/local/nagios/share&quot;</span><span style="color: #000000; font-weight: bold;">&gt;</span>
...
AllowOverride None
Order deny,allow
Deny from all
Allow from 127.0.0.1 10.0.0.25 <span style="color: #666666; font-style: italic;"># Allow single IP addresses</span>
Allow from 10.0.0.0<span style="color: #000000; font-weight: bold;">/</span>255.255.255.0 <span style="color: #666666; font-style: italic;"># Allow network/netmask pair</span>
Allow from 10.0.0.0<span style="color: #000000; font-weight: bold;">/</span><span style="color: #000000;">24</span> <span style="color: #666666; font-style: italic;"># Allow network/nnn CIDR spec</span>
...
<span style="color: #000000; font-weight: bold;">&lt;/</span>Directory<span style="color: #000000; font-weight: bold;">&gt;</span>
<span style="color: #666666; font-style: italic;">## END APACHE CONFIG SNIPPET</span></pre></div></div>

<p>4.Verificación de la configuración de Nagios.<br />
La verificación de que la configuración realizada ha sido correcta, es el proceso más sencillo de<br />
todo el procedimiento y lo podemos ejecutar cada vez que modifiquemos alguno de los archivos de<br />
configuración para comprobar que no tengamos ningún error; y en caso de tenerlo siempre nos<br />
informará en que archivo es.<br />
El comando para realizar esta verificación y volver a arrancar el servicio es el siguiente:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">$ <span style="color: #007800;">$NAGIOSHOME</span><span style="color: #000000; font-weight: bold;">/</span>bin<span style="color: #000000; font-weight: bold;">/</span>nagios <span style="color: #660033;">-v</span> <span style="color: #007800;">$NAGIOSHOME</span><span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>nagios.cfg
$ <span style="color: #007800;">$NAGIOSHOME</span><span style="color: #000000; font-weight: bold;">/</span>bin<span style="color: #000000; font-weight: bold;">/</span>nagios <span style="color: #660033;">-d</span> <span style="color: #007800;">$NAGIOSHOME</span><span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>nagios.cfg</pre></div></div>

<p>En caso de que el cliente nos comentara que tiene algún problema con el “status map”, podemos<br />
ejecutar el siguiente comando:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">$ crle <span style="color: #660033;">-l</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>lib:<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>lib:<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>ssl<span style="color: #000000; font-weight: bold;">/</span>lib:<span style="color: #000000; font-weight: bold;">/</span>opt<span style="color: #000000; font-weight: bold;">/</span>sfw<span style="color: #000000; font-weight: bold;">/</span>lib</pre></div></div>

<p>Nos debería mostrar algo así:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">**</span> Configuration summary <span style="color: #000000; font-weight: bold;">for</span> gd 2.0.35:
Support <span style="color: #000000; font-weight: bold;">for</span> PNG library: <span style="color: #c20cb9; font-weight: bold;">yes</span>
Support <span style="color: #000000; font-weight: bold;">for</span> JPEG library: <span style="color: #c20cb9; font-weight: bold;">yes</span>
Support <span style="color: #000000; font-weight: bold;">for</span> Freetype 2.x library: no
Support <span style="color: #000000; font-weight: bold;">for</span> Fontconfig library: no
Support <span style="color: #000000; font-weight: bold;">for</span> Xpm library: <span style="color: #c20cb9; font-weight: bold;">yes</span>
Support <span style="color: #000000; font-weight: bold;">for</span> pthreads: <span style="color: #c20cb9; font-weight: bold;">yes</span></pre></div></div>

<p>Esta instalación fue realizada bajo Solaris</p>
]]></content:encoded>
			<wfw:commentRss>http://www.boscolopez.com/?feed=rss2&amp;p=316</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Backdoor en UnrealIRCD para servidores Linux</title>
		<link>http://www.boscolopez.com/?p=311</link>
		<comments>http://www.boscolopez.com/?p=311#comments</comments>
		<pubDate>Mon, 14 Jun 2010 19:48:05 +0000</pubDate>
		<dc:creator>Bosco López</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Seguridad]]></category>

		<guid isPermaLink="false">http://www.boscolopez.com/?p=311</guid>
		<description><![CDATA[Leyendo las noticias del día me encuentro en ZDNet con un titular curioso sobre una infección en servidores Linux. Cuando lo comienzo a leer y veo que trata sobre el Unreal Tournament mi interés es mayor ya que he sido un apasionado de este juego. Para los que descargasen la versión servidor Unreal3.2.8.1.tar.gz desde Noviembre [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.boscolopez.com/wp-content/uploads/2010/06/uttux.gif"><img src="http://www.boscolopez.com/wp-content/uploads/2010/06/uttux-150x150.gif" alt="" title="Unreal Tournament TUX" width="150" height="150" class="alignleft size-thumbnail wp-image-312" /></a>Leyendo las noticias del día me encuentro en ZDNet con un titular curioso sobre una infección en servidores Linux. Cuando lo comienzo a leer y veo que trata sobre el Unreal Tournament mi interés es mayor ya que he sido un apasionado de este juego.<br />
Para los que descargasen la versión servidor Unreal3.2.8.1.tar.gz desde Noviembre del 2009 hasta el día de hoy deben aplicar un parche o volver a descargar la versión ya que este backdoor permite ejecutar comandos desde el IRCD con los privilegios del usuario que ejecuta este demonio.</p>
<p>Los md5 para verificar son los siguientes:<br />
7b741e94e867c0a7370553fd01506c66 Unreal3.2.8.1.tar.gz<br />
5a6941385cd04f19d9f4241e5c912d18 Unreal3.2.8.1.exe<br />
a54eafa6861b6219f4f28451450cdbd3 Unreal3.2.8.1-SSL.exe</p>
<p>Para los que no puedan esperar a descargar de nuevo la versión, pueden encontrar un parche e información <a href="http://dl.dropbox.com/u/693961/vbirc_trojan_scan_unrealircd.txt">aquí</a><br />
Las versiones Windows no se vieron afectadas, ya que solo se reemplazó la versión para Linux en los mirror&#8217;s.<br />
Se puede leer la noticia <a href="http://forums.unrealircd.com/viewtopic.php?t=6562">aquí </a>y <a href="http://www.zdnet.com/blog/bott/linux-infection-proves-windows-malware-monopoly-is-over/2206?tag=nl.e550">aquí</a></p>
<p>Como detalle, me extraña que desde noviembre nadie reportase este fallo hasta el 12 de Junio del 2010, suerte a los administradores que tengan que dar ahora explicaciones.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.boscolopez.com/?feed=rss2&amp;p=311</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
		<item>
		<title>Recuperar Active Directory desde AD Restore Mode</title>
		<link>http://www.boscolopez.com/?p=307</link>
		<comments>http://www.boscolopez.com/?p=307#comments</comments>
		<pubDate>Tue, 08 Jun 2010 03:00:28 +0000</pubDate>
		<dc:creator>Bosco López</dc:creator>
				<category><![CDATA[Windows]]></category>

		<guid isPermaLink="false">http://www.boscolopez.com/?p=307</guid>
		<description><![CDATA[Hoy asistí a una avería algo curiosa y que me ha dejado el gusanillo por dentro. Como no teníamos permiso para tocar solamente se nos solicitaba levantar el servidor y que el Dpto. de Sistemas del cliente realizara las operaciones oportunas, me he limitado a realizar lo que se solicitaba. El caso es el siguiente: [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.boscolopez.com/wp-content/uploads/2010/06/winserver2003.gif"><img class="alignleft size-thumbnail wp-image-308" title="Windows Server 2003" src="http://www.boscolopez.com/wp-content/uploads/2010/06/winserver2003-150x150.gif" alt="" width="150" height="150" /></a>Hoy asistí a una avería algo curiosa y que me ha dejado el gusanillo por dentro. Como no teníamos permiso para tocar solamente se nos solicitaba levantar el servidor y que el Dpto. de Sistemas del cliente realizara las operaciones oportunas, me he limitado a realizar lo que se solicitaba.</p>
<p>El caso es el siguiente: Por un extraño motivo el equipo no puede arrancar en ningún otro modo que no sea Active Directory Restore Mode, así que entiendo que es posible que el Active Directory se encuentre corrupto o fuese dando errores y no se solucionasen a tiempo.</p>
<p>La idea era depromocionar el servidor y así &#8220;supuestamente&#8221; arrancaría en modo normal y se podría volver a promocionar. Es una idea algo Heavy, pero si funciona realmente sería la buena. Esta idea no les funcionó así que en principio toca maquetar el server desde cero.</p>
<p>Reinstalar equipo así por que así es algo que odio, prefiero gastar todos los cartuchos, se que lleva más tiempo, pero me gusta más extrujarme el cerebelo que dar por perdida la batalla.</p>
<p>He creado una máquina virtual y provoqué el mismo fallo que tenía ese servidor para ver posibles soluciones.</p>
<p>Lo primero es que lógicamente en modo restauración la consola está algo capada así que lo primero que hice fue ejecutar el comando:  <em>set safeboot_option=DSREPAIR</em></p>
<p>Esto ya me permite acceder a las opciones protegidas de NTDSUTIL</p>
<p>Lo siguiente ha sido verificar el estado de los archivos ejecutando el comando: <em>ntdsutil files info</em></p>
<p>Esto nos muestra las rutas donde están los archivos ntds.dit,dsadata.bak,temp.edb y los logs.</p>
<p>Estas rutas deben coincidir con las mostradas en <strong><em>HKEY_LOCAL_MACHINES\System\CurrentControlSet\Services\NTDS\Parameters</em></strong></p>
<p>Pasamos a comprobar la integridad de la base de datos de Active Directory: <em>ntdsutil file integrity</em></p>
<p>Como era de esperar nos muestra que tenemos errores asi que primero ejecutamos un análisis con el comando:<em> ntdsutil &#8220;sem d a &#8221; go</em></p>
<p>Al mostrarnos errores ejecutamos: <em>ntdsutil &#8220;sem d a&#8221;  &#8220;go f&#8221;</em></p>
<p>Ahora procederemos a realizar una desfragmentación de la bdd</p>
<p><em>compact to &#8220;d:\backup&#8221;</em></p>
<p>Si la desfragmentación termina sin errores copiamos el nuevo<em> Ntds.dit</em> a su ubicación original.</p>
<p>Una vez realizado todo esto, reiniciamos y wuala, tenemos el servidor operativo.</p>
<p>También he visto que Microsoft desaconseja el uso del comando ntdsutil files repair, ya que para reparar elimina ciertos objetos.</p>
<p>Una opción que probaré otro día será depromocionar utilizando ntdsutil que se realizaría de la siguiente manera para los interesados:</p>
<p>En la consola escribimos:</p>

<div class="wp_syntax"><div class="code"><pre class="dos" style="font-family:monospace;">ntdsutil
&nbsp;
metadata cleanup
&nbsp;
connections
&nbsp;
connect to server ServidorAdActivo
&nbsp;
q
&nbsp;
Select operation target
&nbsp;
list domains
&nbsp;
Select domain <span style="color: #cc66cc;">0</span>
&nbsp;
List sites
&nbsp;
Select site <span style="color: #cc66cc;">0</span>
&nbsp;
List servers <span style="color: #00b100; font-weight: bold;">in</span> site
&nbsp;
select server <span style="color: #cc66cc;">0</span> // Aquí <span style="color: #cc66cc;">0</span> se refiere al número de servidor que queremos quitar
&nbsp;
q
<span style="color: #808080; font-style: italic;">
remove selected server</span>
&nbsp;
quit</pre></div></div>

]]></content:encoded>
			<wfw:commentRss>http://www.boscolopez.com/?feed=rss2&amp;p=307</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Eliminar políticas TI / IT de Blackberry</title>
		<link>http://www.boscolopez.com/?p=303</link>
		<comments>http://www.boscolopez.com/?p=303#comments</comments>
		<pubDate>Mon, 07 Jun 2010 22:46:27 +0000</pubDate>
		<dc:creator>Bosco López</dc:creator>
				<category><![CDATA[BlackBerry]]></category>
		<category><![CDATA[Seguridad]]></category>

		<guid isPermaLink="false">http://www.boscolopez.com/?p=303</guid>
		<description><![CDATA[Es normal que los dispositivos Blackberry corporativos tengan aplicadas ciertas restricciones por parte de la empresa, como la desactivación del uso de Blackberry Messenger, usar el dispositivo como Modem IP, acceso a servicios de pago del proveedor y un largo etc&#8230; Para aplicar estas directivas el Dpto. TI de nuestra empresa emplea un Servidor BES [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.boscolopez.com/wp-content/uploads/2010/06/blackberry_8900.jpg"><img class="alignleft size-thumbnail wp-image-304" title="blackberry_8900" src="http://www.boscolopez.com/wp-content/uploads/2010/06/blackberry_8900-150x150.jpg" alt="Blackberry 8900 Curve" width="150" height="150" /></a> Es normal que los dispositivos Blackberry corporativos tengan aplicadas ciertas restricciones por parte de la empresa, como la desactivación del uso de Blackberry Messenger, usar el dispositivo como Modem IP, acceso a servicios de pago del proveedor y un largo etc&#8230; Para aplicar estas directivas el Dpto. TI de nuestra empresa emplea un Servidor BES (Blackberry Enterprise Server).</p>
<p>Por lo que antes de ponernos a eliminar ninguna directiva, deberíamos estar seguros de lo que vamos a realizar, antes de que nos peguen el toque diciéndonos que no metamos las manos donde no nos llaman.</p>
<p>Pero siendo este el caso de que seas una de esas <em>mentes inquietas</em> y te guste algo más el riesgo o el conocimiento, puedes seguir este procedimiento.</p>
<p>Lo primero de todo es tener instalado el Desktop Manager, que podemos descargar desde la web de Blackberry.</p>
<p>Una vez lo tenemos instalado, nos descargamos este archivo de políticas desde aquí, el cual emplearemos para reemplazar las políticas IT de nuestro dispositivo. Guardaremos el policy.bin en la siguiente ruta de nuestro equipo. <em>C:\Archivos de programa\Research In Motion\BlackBerry\</em></p>
<p>Ahora será el momento de abrir el editor de Registro, que podemos ejecutar desde inicio -&gt; Ejecutar -&gt; escribimos <em>regedit</em> y pulsamos aceptar.</p>
<p>En el registro de Windows nos desplazaremos a:</p>
<p>HKEY_CURRENT_USERS\Software\Research In Motion\Blackberry\PolicyManager</p>
<p>Pulsamos botón derecho sobre PolicyManager y crearemos un nuevo valor alfanumérico</p>
<p>Sobre el nuevo valor, pulsamos botón derecho del ratón y le cambiamos el nombre, llamándole así Path.</p>
<p>Ahora pulsamos dos veces sobre Path y escribimos la ruta donde guardamos policy.bin C:\Archivos de programa\Research In Motion\BlackBerry\policy.bin</p>
<p>Pulsamos aceptar, cerramos el regedit, conectamos la BB al equipo y abrimos el Desktop manager. Una vez lo reconozca cambiará las políticas y en algunos casos tendremos que volver a escribir los datos de propietario.</p>
<p>Espero que os fuese tan útil como a mí.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.boscolopez.com/?feed=rss2&amp;p=303</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>Integrando Active Directory en tus scripts de PHP</title>
		<link>http://www.boscolopez.com/?p=299</link>
		<comments>http://www.boscolopez.com/?p=299#comments</comments>
		<pubDate>Sun, 16 May 2010 01:49:45 +0000</pubDate>
		<dc:creator>Bosco López</dc:creator>
				<category><![CDATA[Programación]]></category>
		<category><![CDATA[Windows]]></category>

		<guid isPermaLink="false">http://www.boscolopez.com/?p=299</guid>
		<description><![CDATA[Desde hace 5 meses estoy desarrollando un sistema web para la gestión y administración de incidencias, lógicamente lo hago en mis ratos libres y para eso no en todos sino solo cuando tengo realmente ganas de picar código o estoy realmente aburrido. Una de las cosas que querían integrar en el sistema era que la [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.boscolopez.com/wp-content/uploads/2010/05/imglogophp.png"><img class="alignleft size-thumbnail wp-image-300" title="Logo PHP" src="http://www.boscolopez.com/wp-content/uploads/2010/05/imglogophp-150x150.png" alt="Logo PHP" width="150" height="150" /></a> Desde hace 5 meses estoy desarrollando un sistema web para la gestión y administración de incidencias, lógicamente lo hago en mis ratos libres y para eso no en todos sino solo cuando tengo realmente ganas de picar código o estoy realmente aburrido.</p>
<p>Una de las cosas que querían integrar en el sistema era que la identificación de los usuarios dependiera del Active Directoy, para que así no hubiera 400 passwords diferentes dentro de la intranet y que cada X tiempo el usuario tenga que cambiar todas las passwords, provocando así olvidos y restablecimientos de contraseña sin sentido.</p>
<p>Se que con ASP lo hubiera logrado en un periquete,  pero como nunca se me dió por realizar webs utilizando ese lenguaje, he preferido seguir con el que llevo ya unos cuantos años y varios proyectos realizados.</p>
<p>Buscando información, revisando foros y algunos manuales que me encontré por internet, dí con la información proporcionada por Jason Gilmore, el cual, me permitió verificar que la idea de poder integrar el sistema de autentificación con el LDAP sería posible.</p>
<p>Como requisitos debemos tener instalado y configurado OpenLDAP y Bind9.net.</p>
<p>Para conseguir esto lo primero que hice fue configurar el PHP con las extensiones de LDAP, así que me tocó reconfigurar el servidor:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">.<span style="color: #000000; font-weight: bold;">/</span>configure <span style="color: #660033;">--with-ldap</span></pre></div></div>

<p>Con esto ya podía empezar a dar vueltas a los scripts de ejemplo que adjunta Jason Gilmore en su artículo y que os dejo para que podáis echarles un vistazo:</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">&lt;?php</span>
    <span style="color: #990000;">ldap_connect</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;boscolopez.com&quot;</span><span style="color: #009900;">&#41;</span> or
                  <span style="color: #990000;">die</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;No se puede conectar al Active Directory!&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #000000; font-weight: bold;">?&gt;</span></pre></div></div>


<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">&lt;?php</span>
    <span style="color: #000088;">$ad</span> <span style="color: #339933;">=</span> <span style="color: #990000;">ldap_connect</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;ldap://boscolopez.com&quot;</span><span style="color: #009900;">&#41;</span>
          or <span style="color: #990000;">die</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;No se puede conectar al Active Directory!&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
    <span style="color: #000088;">$bd</span> <span style="color: #339933;">=</span> <span style="color: #990000;">ldap_bind</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$ad</span><span style="color: #339933;">,</span><span style="color: #0000ff;">&quot;usuario@boscolopez.com&quot;</span><span style="color: #339933;">,</span><span style="color: #0000ff;">&quot;password&quot;</span><span style="color: #009900;">&#41;</span>
          or <span style="color: #990000;">die</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;No se puede conectar :( !&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #000000; font-weight: bold;">?&gt;</span></pre></div></div>

]]></content:encoded>
			<wfw:commentRss>http://www.boscolopez.com/?feed=rss2&amp;p=299</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Kit indispensable para un técnico [PARTE II]</title>
		<link>http://www.boscolopez.com/?p=295</link>
		<comments>http://www.boscolopez.com/?p=295#comments</comments>
		<pubDate>Sat, 13 Mar 2010 23:24:58 +0000</pubDate>
		<dc:creator>Bosco López</dc:creator>
				<category><![CDATA[Hardware]]></category>
		<category><![CDATA[Scripting]]></category>
		<category><![CDATA[Windows]]></category>

		<guid isPermaLink="false">http://www.boscolopez.com/?p=295</guid>
		<description><![CDATA[Al igual que siempre he considerado que poseer las herramientas necesarias y tener un buen kit de material es necesario, lo considero igual de importante llevar el software adecuado para cada momento. En un pendrive se pueden llevar un montón archivos, directorios sin sentido y al final creamos un nuevo concepto de baúl de los [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.boscolopez.com/wp-content/uploads/2010/03/soft-pen.jpg"><img class="alignleft size-medium wp-image-296" title="Software Pendrive" src="http://www.boscolopez.com/wp-content/uploads/2010/03/soft-pen-243x300.jpg" alt="" width="243" height="300" /></a> Al igual que siempre he considerado que poseer las herramientas necesarias y tener un buen kit de material es necesario, lo considero igual de importante llevar el software adecuado para cada momento.</p>
<p>En un pendrive se pueden llevar un montón archivos, directorios sin sentido y al final creamos un nuevo concepto de baúl de los recuerdos pero en nuestro maravilloso pendrive.</p>
<p>Esto que comentaba me ha pasado durante todos los pendrives que han pasado por mis manos y que me he dejado olvidados en clientes, los he perdido por algún rincón del coche, en un bolsillo de algún pantalón o etc..</p>
<p>En el último que adquirí un Patriot de 4GB, decidí perder unas horitas pero ordenar el pendrive y hasta generarme un autoexec con los aplicativos o con una GUI para ejecutarlos. Eso ha sido sencillo ya que el PSTART (Personal Start Menu) ya estaba inventado así que ni picar ni una línea de código.</p>
<p>Solo me hizo falta recolectar y agrupar todo lo que suelo utilizar o aplicativos que en algún momento me hicieron falta y me resultaron útiles&#8230; es bien cierto que siempre se pueden volver a descargar cuando los necesitas, pero terminas cansándote de las líneas que tienen clientes, equipos que no tienen acceso a internet, encontrarte en situaciones en las que no posees otro medio que lo que ya tengas en tus manos y un largo etc&#8230; que apuesto que en vuestras mentes podéis encontrar.</p>
<p>Paso a relatar el Software que llevo en el Pendrive y los apartados:</p>
<p><strong>Administración de Servidores:</strong></p>
<p><strong>- </strong>AccesEnum:</p>
<p>Enumera los permisos del directorio o unidad seleccionada, mostrando así los permisos de lectura y escritura sobre cada archivo.</p>
<p>- Active Directory Editor:</p>
<p>Creo que su nombre lo dice todo&#8230; Es un editor de directorios activos</p>
<p>- LDAP Monitor:</p>
<p>Monitorización de ldap&#8217;s, necesario cuando comienzas a tener demasiados usuarios o una carga importante de replicaciones.</p>
<p>- Autologon:</p>
<p>Genera sin modificaciones del registro un autologin en Windows, maravilloso para los TPV&#8217;s que pertenecen a un active directory y el tiempo que te permite ahorrar es crucial.</p>
<p>- AdRestore:</p>
<p>Espero que nunca os encontreis en el caso de tener que utilizarlo, pero si es así para recuperar los tombstone de una manera rápida y sencilla es la herramienta perfecta.</p>
<p>- AutoStart Progam Viewer:</p>
<p>Probarlo, simplemente os diré eso. Os asombareis de todo lo que se autoinicia en un equipo.</p>
<p>- BgInfo:</p>
<p>Si teneis que dar soporte a una red grande, en vez de tener que decir Inicio -&gt; Ejecutar -&gt; CMD -&gt; Ipconfig&#8230;. Mire en la parte superior derecha de su pantalla que valor tiene como IP, que Hostname pone&#8230; Es un generador de información para añadir al Background de Windows. Yo lo propago directamente por directivas y el resultado es comodidad.</p>
<p>- CacheSet:</p>
<p>Modificación de la Cache o vaciado de la misma.</p>
<p>- DebugView:</p>
<p>Es un visor bastante sencillito</p>
<p>- Disk Monitor:</p>
<p>Monitorización de discos</p>
<p>- SID Generator:</p>
<p>Generador automático de SID o modificación del actual.</p>
<p>- Runas:</p>
<p>Ejecutar un aplicativo con privilegios de otro usuario, sin lanzar una ristra desde el cmd.</p>
<p>- Psexec:</p>
<p>Ejecutar un aplicativo en un equipo remoto, bastante útil si no tienes acceso al escritorio remoto y quieres instalarle un VNC.</p>
<p>- WakeOnlan:</p>
<p>Arrancar un equipo apagado.</p>
<p><strong>Administración de directorios</strong></p>
<p>- JkDefrag:</p>
<p>Desfragmentador de unidades.</p>
<p>- DriveImage:</p>
<p>Generación o restauración de imágenes de unidades.</p>
<p>- Explore2fs:</p>
<p>Visor de particiones Linux.</p>
<p>- Double Killer:</p>
<p>Buscador de archivos duplicados, ojo a pasarlo en unidades de backup&#8230; jajajaja</p>
<p>- DeepBurner:</p>
<p>Grabar cd&#8217;s o dvd&#8217;s de una forma rápida.</p>
<p>- 7-Zip:</p>
<p>Compresor y descompresor de archivos</p>
<p>- Pc-Decrap:</p>
<p>Desinstalador de software.</p>
<p><strong>Aplicaciones de red</strong></p>
<p>- Putty</p>
<p>Cliente SSH, telnet, raw, rlogin, serial&#8230; ¿no lo llevas?????</p>
<p>- Network Stumbler</p>
<p>Escaner de redes wifi</p>
<p>********************************</p>
<p>Sigo más tarde</p>
<p>********************************</p>
]]></content:encoded>
			<wfw:commentRss>http://www.boscolopez.com/?feed=rss2&amp;p=295</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
	</channel>
</rss>
