<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" media="screen" href="/~d/styles/rss2full.xsl"?><?xml-stylesheet type="text/css" media="screen" href="http://feeds.feedburner.com/~d/styles/itemcontent.css"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" version="2.0">
<channel>
    <title>Posteet: linux</title> 
    <link>http://www.posteet.com/</link> 
    <description>Recent posteets posted to Posteet</description>
    <ttl>60</ttl>

    
    <atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="self" type="application/rss+xml" href="http://feeds.feedburner.com/posteet_linux" /><feedburner:info uri="posteet_linux" /><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="hub" href="http://pubsubhubbub.appspot.com/" /><item>
        <title>auditd useful commands</title>
        <link>http://feedproxy.google.com/~r/posteet_linux/~3/eE572u-FJEE/2171</link>
        <description>
        <![CDATA[<pre>#Adding/Modifying Rules

#    Watch for files 

auditctl -w /etc/yum.conf -p wa  -k yum_watch
auditctl -w /usr/bin/nmap -p x   -k nmap_watch
auditctl -w /etc/shadow   -p rwa -k shadow_watch

#    Remove a rule using auditctl 

auditctl -W /etc/shadow -p rwa -k shadow_watch

#    Watching for ptrace system call 

auditctl -a entry,always -F arch=b64 -S ptrace -k info_scan

#    Suppress 32bit clock_gettime &amp; fstat64 system calls 

-a entry,never -F arch=b32 -S clock_gettime -k clock_gettime
-a entry,never -F arch=b32 -S fstat64 -k fstat64

#    Audit files opened by a specific user 

auditctl -a exit,always -S open -F auid=2010
auditctl -a exit,always -F arch=b64 -F auid=2010  -F uid=2010 -F path=/etc/hosts -S open

#    Audit unsuccessful attempts for multiple system calls where user id is greater than or equal to 500 

auditctl -a always,exit -F arch=b32 -S creat -S open -S openat -S truncate -S ftruncate -F exit=-EACCES -F auid&gt;=500 
auditctl -a always,exit -F arch=b32 -S creat -S open -S openat -S truncate -S ftruncate -F exit=-EPERM -F auid&gt;=500 

#Reporting/Searching

#    List all rules 

auditctl -l

#    List status 

auditctl -s

#    Report on watched files. Date format is local to the server's date format. 

aureport -f
aureport -f --start 02/18/10 17:42:00
aureport -f --start 02/18/10 17:00:00 --end 02/18/10 17:10:00
aureport -f -ts this-week
aureport -f -ts today

#    Search by system call 

ausearch -sc ptrace -i

#    Search for user id or effective user id 

ausearch -ui 2010
ausearch -ue 2010

#    Lists all auth attempts and their result 

aureport -au

#    List just logins 

aureport -l

#    List account modification attempts. 

aureport -m

#    Search events where success value is no, User id is 500 and key is nmap_watch 

ausearch -sv no -ua 500 -k nmap_watch

#    Search by executable 

ausearch -x /usr/bin/nmap

#    Search by terminal 

ausearch -tm pts/0

#    Search by daemon. Stuff like cron log terminal as the daemon name 

ausearch -tm cron</pre> <a href="http://www.posteet.com/tags/audit">[audit]</a>  <a href="http://www.posteet.com/tags/auditd">[auditd]</a>  <a href="http://www.posteet.com/tags/audtictl">[audtictl]</a>  <a href="http://www.posteet.com/tags/ausearch">[ausearch]</a>  <a href="http://www.posteet.com/tags/linux">[linux]</a>  <a href="http://www.posteet.com/tags/unix">[unix]</a> ]]>        </description>
        <dc:creator>spirit</dc:creator>
        <pubDate>Tue, 16 Apr 2013 16:54:26 -0500</pubDate>

            <category>audit</category>
            <category>auditd</category>
            <category>audtictl</category>
            <category>ausearch</category>
            <category>linux</category>
            <category>unix</category>
    
    <feedburner:origLink>http://www.posteet.com/view/2171</feedburner:origLink></item>

  
    <item>
        <title>Reboot blocked Linux server</title>
        <link>http://feedproxy.google.com/~r/posteet_linux/~3/s_x9SyfGYTk/2163</link>
        <description>
        <![CDATA[<pre>alt + impr ecran r e i s u  b</pre> <a href="http://www.posteet.com/tags/linux">[linux]</a>  <a href="http://www.posteet.com/tags/reboot">[reboot]</a>  <a href="http://www.posteet.com/tags/server">[server]</a> ]]>        </description>
        <dc:creator>spirit</dc:creator>
        <pubDate>Mon, 14 Jan 2013 13:49:49 -0600</pubDate>

            <category>linux</category>
            <category>reboot</category>
            <category>server</category>
    
    <feedburner:origLink>http://www.posteet.com/view/2163</feedburner:origLink></item>

  
    <item>
        <title>Traffic visualizer under Linux</title>
        <link>http://feedproxy.google.com/~r/posteet_linux/~3/_KFZtRqF2zw/2162</link>
        <description>
        <![CDATA[<pre>iptraf
jnettop
iftop</pre> <a href="http://www.posteet.com/tags/linux">[linux]</a>  <a href="http://www.posteet.com/tags/traffic">[traffic]</a> ]]>        </description>
        <dc:creator>spirit</dc:creator>
        <pubDate>Mon, 14 Jan 2013 13:48:31 -0600</pubDate>

            <category>linux</category>
            <category>traffic</category>
    
    <feedburner:origLink>http://www.posteet.com/view/2162</feedburner:origLink></item>

  
    <item>
        <title>Prompt linux</title>
        <link>http://feedproxy.google.com/~r/posteet_linux/~3/k1DIJAidPf4/2156</link>
        <description>
        <![CDATA[<pre>PS1=&quot;\[\e[30;1m\](\[\e[34;1m\]\A\e[30;1m\])-(\[\e[34;1m\]\u@\h\[\e[30;1m\]\[\e[30;1m\]:\[\[\e[32;1m\]\w\[\e[30;1m\])&gt; \[\e[0m\]&quot;</pre> <a href="http://www.posteet.com/tags/linux">[linux]</a>  <a href="http://www.posteet.com/tags/prompt">[prompt]</a>  <a href="http://www.posteet.com/tags/shell">[shell]</a> ]]>        </description>
        <dc:creator>spirit</dc:creator>
        <pubDate>Thu, 06 Dec 2012 13:21:09 -0600</pubDate>

            <category>linux</category>
            <category>prompt</category>
            <category>shell</category>
    
    <feedburner:origLink>http://www.posteet.com/view/2156</feedburner:origLink></item>

  
    <item>
        <title>Send syslog message with netcat nc</title>
        <link>http://feedproxy.google.com/~r/posteet_linux/~3/bHoNusCozYQ/2143</link>
        <description>
        <![CDATA[<pre>echo &quot;&lt;150&gt;`env LANG=us_US.UTF-8 date &quot;+%b %d %H:%M:%S&quot;` host`date +%s` service: my special message goes here&quot; | nc 192.168.0.1 -u 514 -w 1</pre> <a href="http://www.posteet.com/tags/linux">[linux]</a>  <a href="http://www.posteet.com/tags/loger">[loger]</a>  <a href="http://www.posteet.com/tags/nc">[nc]</a>  <a href="http://www.posteet.com/tags/netcat">[netcat]</a>  <a href="http://www.posteet.com/tags/syslog">[syslog]</a> ]]>        </description>
        <dc:creator>spirit</dc:creator>
        <pubDate>Wed, 22 Aug 2012 13:26:13 -0500</pubDate>

            <category>linux</category>
            <category>loger</category>
            <category>nc</category>
            <category>netcat</category>
            <category>syslog</category>
    
    <feedburner:origLink>http://www.posteet.com/view/2143</feedburner:origLink></item>

  
    <item>
        <title>Bibliotecas en linux</title>
        <link>http://feedproxy.google.com/~r/posteet_linux/~3/cF7vuRfncOI/2142</link>
        <description>
        <![CDATA[<pre>Listado de las rutas de bibliotecas del sistema: /etc/ld.so.confex
Además se incluyen las rutas de la variable de entrono: $LD_LIBRARY_PATH
Mostrar las bibliotecas dependientes de un programa: ldd /bin/ls
Recargar la cache de bibliotecas: ldconfig</pre> <a href="http://www.posteet.com/tags/linux">[linux]</a> ]]>        </description>
        <dc:creator>leomarcov</dc:creator>
        <pubDate>Thu, 12 Jul 2012 13:20:12 -0500</pubDate>

            <category>linux</category>
    
    <feedburner:origLink>http://www.posteet.com/view/2142</feedburner:origLink></item>

  
    <item>
        <title>Enable/Disable MySQL Log</title>
        <link>http://feedproxy.google.com/~r/posteet_linux/~3/uP7SP1boGBk/2138</link>
        <description>
        <![CDATA[<pre># Enable
mysql&gt; SET GLOBAL general_log = 'ON';

# On Debian, you can check log on /var/run/mysqld/mysqld.log
tail -f /var/run/mysqld/mysqld.log

# Disable
mysql&gt; SET GLOBAL general_log = 'OFF';</pre> <a href="http://www.posteet.com/tags/linux">[linux]</a>  <a href="http://www.posteet.com/tags/mysql">[mysql]</a> ]]>        </description>
        <dc:creator>sox</dc:creator>
        <pubDate>Thu, 24 May 2012 12:46:13 -0500</pubDate>

            <category>linux</category>
            <category>mysql</category>
    
    <feedburner:origLink>http://www.posteet.com/view/2138</feedburner:origLink></item>

  
    <item>
        <title>Finding All Hosts On the LAN From Linux / Windows Workstation</title>
        <link>http://feedproxy.google.com/~r/posteet_linux/~3/3lB_Fb7QZGQ/2130</link>
        <description>
        <![CDATA[<pre>#Linux
for ip in $(seq 1 254); do ping -c 1 192.168.1.$ip&gt;/dev/null; [ $? -eq 0 ] &amp;&amp; echo &quot;192.168.1.$ip UP&quot; || : ; done

#Windows:
for /L %I in (1,1,254) DO ping -w 30 -n 1 192.168.1.%I | find &quot;Reply&quot;</pre> <a href="http://www.posteet.com/tags/bash">[bash]</a>  <a href="http://www.posteet.com/tags/bat">[bat]</a>  <a href="http://www.posteet.com/tags/hosts">[hosts]</a>  <a href="http://www.posteet.com/tags/lan">[lan]</a>  <a href="http://www.posteet.com/tags/linux">[linux]</a>  <a href="http://www.posteet.com/tags/ping">[ping]</a>  <a href="http://www.posteet.com/tags/up">[up]</a>  <a href="http://www.posteet.com/tags/windows">[windows]</a> ]]>        </description>
        <dc:creator>spirit</dc:creator>
        <pubDate>Sun, 22 May 2011 15:36:22 -0500</pubDate>

            <category>bash</category>
            <category>bat</category>
            <category>hosts</category>
            <category>lan</category>
            <category>linux</category>
            <category>ping</category>
            <category>up</category>
            <category>windows</category>
    
    <feedburner:origLink>http://www.posteet.com/view/2130</feedburner:origLink></item>

  
    <item>
        <title>enlever règle iptable</title>
        <link>http://feedproxy.google.com/~r/posteet_linux/~3/wEQRnoomhFM/2129</link>
        <description>
        <![CDATA[<pre>iptables -D table -s IP -j DROP</pre> <a href="http://www.posteet.com/tags/failtoban">[failtoban]</a>  <a href="http://www.posteet.com/tags/firewall">[firewall]</a>  <a href="http://www.posteet.com/tags/iptables">[iptables]</a>  <a href="http://www.posteet.com/tags/linux">[linux]</a> ]]>        </description>
        <dc:creator>neorom</dc:creator>
        <pubDate>Mon, 16 May 2011 11:12:01 -0500</pubDate>

            <category>failtoban</category>
            <category>firewall</category>
            <category>iptables</category>
            <category>linux</category>
    
    <feedburner:origLink>http://www.posteet.com/view/2129</feedburner:origLink></item>

  
    <item>
        <title>rsyslog TCP forwarding</title>
        <link>http://feedproxy.google.com/~r/posteet_linux/~3/qMLxuotBL2k/2121</link>
        <description>
        <![CDATA[<pre>In the format shown above, UDP is used for transmitting the message. The destination port is set to the default auf 514. Rsyslog is also capable of using much more secure and reliable TCP sessions for message forwarding. Also, the destination port can be specified. To select TCP, simply add one additional @ in front of the host name (that is, @host is UPD, @@host is TCP). For example:


*.* @@finlandia

To specify the destination port on the remote machine, use a colon followed by the port number after the machine name. The following forwards to port 1514 on finlandia:


*.* @@finlandia:1514

This syntax works both with TCP and UDP based syslog. However, you will probably primarily need it for TCP, as there is no well-accepted port for this transport (it is non-standard). For UDP, you can usually stick with the default auf 514, but might want to modify it for security rea-
sons. If you would like to do that, it's quite easy:


*.* @finlandia:151</pre> <a href="http://www.posteet.com/tags/debian">[debian]</a>  <a href="http://www.posteet.com/tags/forward">[forward]</a>  <a href="http://www.posteet.com/tags/forwarding">[forwarding]</a>  <a href="http://www.posteet.com/tags/linux">[linux]</a>  <a href="http://www.posteet.com/tags/rsyslog">[rsyslog]</a>  <a href="http://www.posteet.com/tags/syslog">[syslog]</a>  <a href="http://www.posteet.com/tags/TCP">[TCP]</a> ]]>        </description>
        <dc:creator>neorom</dc:creator>
        <pubDate>Tue, 22 Feb 2011 17:08:09 -0600</pubDate>

            <category>debian</category>
            <category>forward</category>
            <category>forwarding</category>
            <category>linux</category>
            <category>rsyslog</category>
            <category>syslog</category>
            <category>TCP</category>
    
    <feedburner:origLink>http://www.posteet.com/view/2121</feedburner:origLink></item>

  
    <item>
        <title>Find files modified in the last two days</title>
        <link>http://feedproxy.google.com/~r/posteet_linux/~3/3cGvqs3tl0k/2113</link>
        <description>
        <![CDATA[<pre>find / -mtime 2 -o -ctime 2</pre> <a href="http://www.posteet.com/tags/bash">[bash]</a>  <a href="http://www.posteet.com/tags/ctime">[ctime]</a>  <a href="http://www.posteet.com/tags/files">[files]</a>  <a href="http://www.posteet.com/tags/find">[find]</a>  <a href="http://www.posteet.com/tags/linux">[linux]</a>  <a href="http://www.posteet.com/tags/modifications">[modifications]</a>  <a href="http://www.posteet.com/tags/mtime">[mtime]</a>  <a href="http://www.posteet.com/tags/shell">[shell]</a> ]]>        </description>
        <dc:creator>spirit</dc:creator>
        <pubDate>Tue, 14 Dec 2010 23:05:57 -0600</pubDate>

            <category>bash</category>
            <category>ctime</category>
            <category>files</category>
            <category>find</category>
            <category>linux</category>
            <category>modifications</category>
            <category>mtime</category>
            <category>shell</category>
    
    <feedburner:origLink>http://www.posteet.com/view/2113</feedburner:origLink></item>

  
    <item>
        <title>Find all world writable directories / files</title>
        <link>http://feedproxy.google.com/~r/posteet_linux/~3/tEChDVYQUlk/2112</link>
        <description>
        <![CDATA[<pre>find / -perm -0002 -type d -print
find / -perm -0002 -type f -print</pre> <a href="http://www.posteet.com/tags/bash">[bash]</a>  <a href="http://www.posteet.com/tags/directories">[directories]</a>  <a href="http://www.posteet.com/tags/files">[files]</a>  <a href="http://www.posteet.com/tags/find">[find]</a>  <a href="http://www.posteet.com/tags/linux">[linux]</a>  <a href="http://www.posteet.com/tags/rights">[rights]</a>  <a href="http://www.posteet.com/tags/shell">[shell]</a>  <a href="http://www.posteet.com/tags/writable">[writable]</a> ]]>        </description>
        <dc:creator>spirit</dc:creator>
        <pubDate>Tue, 14 Dec 2010 23:04:49 -0600</pubDate>

            <category>bash</category>
            <category>directories</category>
            <category>files</category>
            <category>find</category>
            <category>linux</category>
            <category>rights</category>
            <category>shell</category>
            <category>writable</category>
    
    <feedburner:origLink>http://www.posteet.com/view/2112</feedburner:origLink></item>

  
    <item>
        <title>Find all files created or updated in the last five minutes</title>
        <link>http://feedproxy.google.com/~r/posteet_linux/~3/7o1K3N-izoo/2111</link>
        <description>
        <![CDATA[<pre>find / -cmin -5</pre> <a href="http://www.posteet.com/tags/bash">[bash]</a>  <a href="http://www.posteet.com/tags/created">[created]</a>  <a href="http://www.posteet.com/tags/files">[files]</a>  <a href="http://www.posteet.com/tags/find">[find]</a>  <a href="http://www.posteet.com/tags/linux">[linux]</a>  <a href="http://www.posteet.com/tags/minutes">[minutes]</a>  <a href="http://www.posteet.com/tags/updated">[updated]</a> ]]>        </description>
        <dc:creator>spirit</dc:creator>
        <pubDate>Tue, 14 Dec 2010 23:03:48 -0600</pubDate>

            <category>bash</category>
            <category>created</category>
            <category>files</category>
            <category>find</category>
            <category>linux</category>
            <category>minutes</category>
            <category>updated</category>
    
    <feedburner:origLink>http://www.posteet.com/view/2111</feedburner:origLink></item>

  
    <item>
        <title>Gestion des routes sous Linux</title>
        <link>http://feedproxy.google.com/~r/posteet_linux/~3/W4uXhqnwJYY/2101</link>
        <description>
        <![CDATA[<pre># Ajouter une route par defaut
route add default gw 192.168.0.1

# Afficher les routes
route -n

# Supprimer une route
route del -net 192.168.0.1/24</pre> <a href="http://www.posteet.com/tags/administration">[administration]</a>  <a href="http://www.posteet.com/tags/linux">[linux]</a>  <a href="http://www.posteet.com/tags/reseau">[reseau]</a>  <a href="http://www.posteet.com/tags/routage">[routage]</a> ]]>        </description>
        <dc:creator>sox</dc:creator>
        <pubDate>Tue, 28 Sep 2010 10:34:46 -0500</pubDate>

            <category>administration</category>
            <category>linux</category>
            <category>reseau</category>
            <category>routage</category>
    
    <feedburner:origLink>http://www.posteet.com/view/2101</feedburner:origLink></item>

  
    <item>
        <title>Manipulations classiques dans une arborescence de fichiers avec sed</title>
        <link>http://feedproxy.google.com/~r/posteet_linux/~3/QFS8vP8A-NI/2089</link>
        <description>
        <![CDATA[<pre>Astuces très simples mais toujours utiles :

- Rechercher/remplacer une occurence dans toute une série de fichiers :
find mon_repertoire -type f -exec sed -i 's/occurence/remplacement/g' {} \;

- Supprimer les lignes contenant une occurence dans une série de fichiers :
find mon_repertoire -type f -exec sed -i 's/occurence/d' {} \;</pre> <a href="http://www.posteet.com/tags/bash">[bash]</a>  <a href="http://www.posteet.com/tags/find">[find]</a>  <a href="http://www.posteet.com/tags/linux">[linux]</a>  <a href="http://www.posteet.com/tags/sed">[sed]</a> ]]>        </description>
        <dc:creator>koudou</dc:creator>
        <pubDate>Wed, 21 Jul 2010 08:52:35 -0500</pubDate>

            <category>bash</category>
            <category>find</category>
            <category>linux</category>
            <category>sed</category>
    
    <feedburner:origLink>http://www.posteet.com/view/2089</feedburner:origLink></item>


</channel>
</rss>
