<?xml version="1.0" encoding="utf-8" ?>

<rss version="0.91" >
<channel>
<title>SIGKILL</title>
<link>http://sigkill.dk/blog/</link>
<description>Hello, World!</description>
<language>en</language>
<image>
        <url>http://sigkill.dk/blog/templates/default/img/s9y_banner_small.png</url>
        <title>RSS: SIGKILL - Hello, World!</title>
        <link>http://sigkill.dk/blog/</link>
        <width>100</width>
        <height>21</height>
    </image>

<item>
    <title>LinkedIn phishing vulnerability</title>
    <link>http://sigkill.dk/blog/archives/311-LinkedIn-phishing-vulnerability.html</link>

    <description>
        &lt;p&gt;The popular social networking site &lt;a
href=&quot;http://linkedin.com&quot;&gt;LinkedIn&lt;/a&gt; suffers from a phishing
vulnerability that makes it possible to take control of another
persons account.  In particular, it is possible to silently attach an
additional email address to another persons account, then use that
email address to reset the password and obtain full control of the
account.  This requires nothing more than the owner of the other
account agreeing to establish a connection.  The procedure is as
follows:&lt;/p&gt;

&lt;ol&gt; &lt;li&gt;On the &lt;em&gt;Add Connections&lt;/em&gt; page, send an invitation to
  an email account that you control.&lt;/li&gt;

  &lt;li&gt;Send the invitation email onwards to your intended victim,
  forging headers as appropriate to make it seem as if the mail came
  from LinkedIn (the forgery does not have to be perfect, most email
  clients will not display the defects).  Notably, do not change the
  contact link within the message.&lt;/li&gt;

  &lt;li&gt;If the victim clicks on the link and accepts the contact, the
  original email address (which you control) will be silently attached
  to the victims account, and you can then request a password reset link
  be sent to it.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;The vulnerability lies in step 3, in that the victim is never
informed that a hidden piece of information (the email provided in
step 1) will be attached to their profile.  While not strictly a
technical problem, the phishing vulnerability is based on an
implementation that does not make the consequences of user actions
explicit, and which embeds potentially harmful information in a
seemingly innocent link.  Problems such as these are every bit as
important as a buffer overflow or XSS-vulnerability, and should be
guarded against just as vigilantly. &lt;/p&gt;

&lt;p&gt;This vulnerability was discovered (and tested!) on a grey afternoon
by &lt;a href=&quot;http://dybber.dk&quot;&gt;Martin Dybdal&lt;/a&gt;, Ulrik Rasmussen, and &lt;a
href=&quot;http://sigkill.dk&quot;&gt;myself&lt;/a&gt;.&lt;/p&gt;
 
    </description>
</item>
<item>
    <title>Den Datamatiske Devolution</title>
    <link>http://sigkill.dk/blog/archives/310-Den-Datamatiske-Devolution.html</link>

    <description>
        &lt;p&gt;
I datamaternes tidligste tid interagerede man med dem ved at ændre dem
direkte: Ved at indstille kontakterne på deres kontrolpanel kunne man
kommunikere med dem i deres eget sprog, i den materielle struktur som
udgjorde deres egentlige eksistens.
&lt;/p&gt;

&lt;p&gt;
Så fik man præcise og veldefinerede skriftsprog, hvor alt havde en
veldefineret og kontrolleret mening: Der var yderst få tvetydigheder,
meningen blev bestemt og veldokumenteret af centrale administrationer,
og det var muligt at kommuniker effektivt og præcist med datamaten, så
snart man havde investeret en moderat mængde tid i at sætte sig ind i
konventionerne.
&lt;/p&gt;

&lt;p&gt;
Med tiden steg mængden af disse skriftsprog eksplosivt: Hver datamat
havde sine egne kommunikationsregler, ja visse enkelte installationer
afviger endda drastisk fra deres naboer, og det kan være utroligt svært
at vide hvordan kommunikationen skal foregå, med mindre man kan spørge
en lokalkendt om råd.
&lt;/p&gt;

&lt;p&gt;
I 80&#039;erne og 90&#039;erne udviklede man for alvor musen og de grafiske
brugergrænseflader, hvor man nu måtte udtrykke sin mening med mere eller
mindre vagt kropssprog.  Nu hvor talegenkendelse er ved at slå igennem
er vi endelig nået mod slutpunktet for devolutionen indenfor
grænseflader: Som jeg har illustreret ovenfor er vi indtil videre gået
modsat evolutionen for menneskeligt talesprog, og derfor er vi snart
reduceret til at pege og grynte ad datamaten for at bibringe vores
intentioner.
&lt;/p&gt;

&lt;p&gt;
Hvis idéen med passive, allestedsværende, indlejrede enheder (&quot;pervasive
computing&quot;) virkelig slår igennem vil vi endda afvikle os til et punkt
hvor vi slet ikke kommunikerer med datamaten længere.  Det tog os
millioner af år at bevæge os den distance med
menneske-til-menneske-kommunikation!  (Omend det naturligvis var i den
anden retning.)
&lt;/p&gt; 
    </description>
</item>
<item>
    <title>Skønlitteratur</title>
    <link>http://sigkill.dk/blog/archives/309-Sknlitteratur.html</link>

    <description>
        &lt;p&gt; I de seneste par uger har jeg genopdaget en interesse som jeg har
forsømt i alt for mange år - læsning af skønlitteratur. Derfor er jeg
gået i gang med at indkøbe og læse en serie af fantasy-romaner skrevet
af min yndlings fantasy-forfatter, Raymond E. Feist. Hans historier,
som tager deres begyndelse med Riftwar-serien, er især værd at læse
fordi de forstår at kombinere det fantastiske med det hverdagsagtige,
på en måde så det fantastiske ikke bliver dagligdags og derved
uinteressant. Tolkiens bøger er baseret på samme koncept, men sætter
dog også et relativt lavt loft over omfanget af supernaturlige
fænomener, hvor Feist nærmest har gjort en sport ud af at gøre den
lejlighedsmæssige magiske indblanding mere og mere ekstrem. En anden
ting, der gør Feists bøger interessante, er at de tilsammen dækker en
meget lang tidsperiode (over 100 år) i hans fiktive verden; man følger
derfor hovedpersoner vokse op, ældes, få børn og dø af naturlige
(eller unaturlige) årsager, hvorefter deres børn tager over. Det giver
verdenen en atmosfære af realisme at de mange store begivenheder
således kan spredes over en længere periode, i modsætning til visse
andre langvarige fantasy-serier som lader til at have potentielt
altødelæggende katastrofer hvert andet år.&lt;/p&gt; 
    </description>
</item>
<item>
    <title>Haskell og Debian</title>
    <link>http://sigkill.dk/blog/archives/308-Haskell-og-Debian.html</link>

    <description>
        &lt;p&gt; Tilbage i 2007 var mit &lt;a
href=&quot;http://sigkill.dk/blog/archives/250-Godt-nytar.html&quot;&gt;nytårsforsæt&lt;/a&gt;
at lære &lt;a href=&quot;http://www.haskell.org&quot;&gt;Haskell&lt;/a&gt;. Eftersom jeg
skriver om det nu, må det vel antages at det ikke blev opfyldt,
hvilket er korrekt. Dog er jeg nu begyndt at rette op på det ved at
læse lærebogen &lt;a
href=&quot;http://www.cs.nott.ac.uk/~gmh/book.html&quot;&gt;Programming in
Haskell&lt;/a&gt; og løse &lt;a
href=&quot;http://projecteuler.net&quot;&gt;Euler-problemer&lt;/a&gt;. Lærebogen er
ganske udemærket, dens eneste brist er at den ikke forudsætter nogen
form for forgående programmeringserfaring og således bruger en del
sider på at beskrive grundlæggende programmeringskoncepter (og bogen
er ikke for tyk til at begynde med). Det lader til at være et generelt
problem med mange af de funktionsorienterede sprog: Stort set alle
tilgængelige bøger er lærebøger beregnet til helt nye programmører, en
situation hvor Common Lisp, der har mesterværker som &lt;a
href=&quot;http://en.wikipedia.org/wiki/The_Art_of_the_Metaobject_Protocol&quot;&gt;Art
of the Metaobject Protocol&lt;/a&gt;, skiller sig noget ud.&lt;/p&gt;

&lt;p&gt;For at opnå erfaring med brug af Haskell i rigtige projekter er jeg
gået over til en ny window manager, &lt;a
href=&quot;http://xmonad.org/&quot;&gt;xmonad&lt;/a&gt;, baseret på den tese at jeg vil
blive så irriteret over diverse ubekvemmeligheder at jeg bliver
motiveret til at ændre i koden. Der er allerede adskillige ting der
irriterer mig (først og fremmest de elendige genvejstaster, et punkt
som &lt;a href=&quot;http://www.nongnu.org/ratpoison/&quot;&gt;ratpoison&lt;/a&gt; har
forvænt mig med).&lt;/p&gt;

&lt;p&gt; Jeg er også begyndt at overveje at droppe Debian som styresystem
til fordel for Ubuntu. Min oprindelige argumentation for at bruge
Debian var at det ville være lettere at vedligeholde Debian end at
tilpasse Ubuntu til mine til tider usædvanlige
præferencer. Efterhånden er jeg begyndt at tvivle på dette, især efter
mit system er begyndt at nægte at vise output på både laptop-skærmen
og den tilsluttede VGA-skærm på samme tid.&lt;/p&gt; 
    </description>
</item>
<item>
    <title>Terroristerne kommer!</title>
    <link>http://sigkill.dk/blog/archives/307-Terroristerne-kommer!.html</link>

    <description>
        &lt;p&gt; Som de fleste vel efterhånden er klar over var der for et par dage
siden et selvmordsangreb på en dansk ambassade i Pakistan. Siden da
har medierne været fyldt med artikler og ledere om at Danmark har
overstrukket sig selv og nu er blevet et terrormål helt på højde med
Storbritannien, USA og Israel. Lad os betragte den handling der
affødte dette hysteri. Det var et terrorangreb, jovist, men det fandt
sted i udlandet, ingen danskere kom til skade og det skete adskillige
år efter den gerning, som det angiveligt skulle hævne. Forstå mig ret,
jeg mener ikke at terrorangreb bliver mindre afskyelige af at der ikke
er dødsfald i min egen klub, men det virker nærmest respektløst at
sammenligne dette med de voldsomme angreb som er sket på
Storbritannien, USA og Israel.&lt;/p&gt;

&lt;p&gt; På sin vis minder det om borgerkrigen i Afghanistan, hvor vi hver
eneste gang en dansk soldat mister livet, får at vide at vi er ved at
tabe krigen og ikke er i stand til at føre den. Det synes jeg igen er
en forvanskning af sandheden. Betragt krigs--statistikkerne: De danske
tropper og deres allierede mister &lt;em&gt;voldsomt&lt;/em&gt; færre mænd end
deres fjender, og i forhold til tidligere krige er den materielle og
personalemæssige investering minimal. Selv Danmark har personligt ført
væsentligt større krige i vor fortid, og dengang var vi langt
fattigere og fåtallige end nu. På nuværende tidspunkt er vores indsats
i Afghanistan, samt terror-&quot;truslen&quot;, langt mere baseret på politisk
vilje end egentlige militære og sikkerhedsmæssige overvejelser. Det
virker mest af alt som et ønske om at slutte sig til de seje lande som
virkelig er i fare for terrorangreb, men i sidste ende er det bare
patetisk.&lt;/p&gt; 
    </description>
</item>
<item>
    <title>#:els:2008</title>
    <link>http://sigkill.dk/blog/archives/306-els2008.html</link>

    <description>
        &lt;p&gt; I have just returned home from the European Lisp Symposium
of 2008, held in Bordeaux, and I shall now inflict upon you my
experiences from the event. &lt;/p&gt;

&lt;p&gt; I&#039;m not a very experienced traveller - indeed, this was my first
time travelling by plane by myself, so I was slightly worried about
getting lost along the way from Copenhagen to Bordeaux. My trip was
fairly uneventful, though I was a bit mystified by travelling via a
KLM-owned &lt;a href=&quot;http://en.wikipedia.org/wiki/Fokker_F100&quot;&gt;Fokker
100&lt;/a&gt;, a plane manufactured by a company that left the business
quite a while ago. I was not less mystified when the rest of the
flight was done in a plane that the safety guide claimed was a &lt;a
href=&quot;http://en.wikipedia.org/wiki/Fokker_50&quot;&gt;Fokker 50&lt;/a&gt;, but which
most assuredly did not have turboprop engines.&lt;/p&gt;

&lt;p&gt;For my part, the stereotype about French people not understanding
English turned out to be fairly true. Even more, the tram ticket
machine did not understand English either, the clearly labelled button
for changing the interface language seemed totally nonfunctional, as
if it was literally just painted on the machine. I was told that the
attitude towards English had changed in France - I can only imagine it
has changed from open disdain to a feeling of irrelevance.&lt;/p&gt;

&lt;p&gt; Anyway, on to the interesting part: the actual symposium, which
spanned over two days. The first day contained confusingly named
&quot;Birds of a feather&quot; sessions (also known as workshops/discussion
sessions). They were quite interesting, though I admit I had too
little interest in parallel programming to be that aware during the
first session. The CLIM/&lt;a
href=&quot;http://common-lisp.net/project/mcclim&quot;&gt; McCLIM&lt;/a&gt; session was
interesting, though my own part in it was pretty much a disaster due
to my SBCL session getting totally messed up in some way. Scott McKay
(the original designer of CLIM) managed to inject some interesting
comments though. Amusingly enough, it did not seem like he had the
same vision for CLIM as I have now, and rather took great pride in how
the spiritual successor (&lt;a
href=&quot;http://wiki.opendylan.org/wiki/view.dsp?title=DUIM&quot;&gt;DUIM&lt;/a&gt; for
Dylan) could perfectly resemble a mainstream, native user
interface. The informal session about the eventual successor to ASDF
was perhaps the most interesting, some actual and involved discussion
ensued and &lt;a href=&quot;http://random-state.net/&quot;&gt;Nikodemus&lt;/a&gt; came up
with the idea for a clever/horrible reader macro that inspired the
title of this blog post. It seems like the ASDF successor will be
motivated by two main things: facilitating a sane ASDF-Install
replacement and elegantly handling weird compilation options. Exactly
what I need, so I won&#039;t complain. I may even contribute code if it
comes to that.&lt;/p&gt;

&lt;p&gt; The presentations were decent, but I found that I learnt more
interesting stuff by talking with the authors than by listening to
their talks, so I&#039;ll elegantly skip to perhaps the most important
thing about the meeting: talking to other Lisp programmers in real
life and finally meeting people I&#039;ve talked to online for years. It
was very educative and entertaining; from listening to Scott McKays
view on CLIM, to discussing more general programming with Christophe
Rhodes and Robert Strandh, to getting a primer on Finnish politics by
Nikodemus Siivola. I obviously can&#039;t give a comprehensive description
of every topic touched by these conversations, but I can encourage
anyone who has never been to one of these events to attend the next
possible one, since actually talking face to face allows some
discussions to work much smoother than they do online. &lt;/p&gt;

&lt;p&gt; Unless practical problems get in the way, I&#039;ll definitely be
attending the next European Lisp Symposium. It was certainly a very
rewarding investment of my time.  &lt;/p&gt;
 
    </description>
</item>
<item>
    <title>Voxels</title>
    <link>http://sigkill.dk/blog/archives/305-Voxels.html</link>

    <description>
        &lt;p&gt; Tænk tilbage på de tidlige halvfemsere, tilbage til
3D-computerspillenes barndom. Dengang var 3D ikke nødvendigvis lig med
polygoner, sådan som de er nu, i stedet var &lt;a
href=&quot;http://en.wikipedia.org/wiki/Voxel&quot;&gt;voxels&lt;/a&gt; (3D-pixels) en
yderst realistisk mulighed. Som alle ved vandt polygonbaserede
spilmotorer stort, hjulpet godt på vej af hardwareacceleration, men
voxels har stadigvæk en fordel i kraft af deres fleksibilitet og gode
understøttelse for kurvede overflader. Et blik på hvordan 3D i stedet
kunne have udviklet sig kan man få ved at prøve &lt;a
href=&quot;http://voxelstein3d.sourceforge.net/&quot;&gt;Voxelstein 3D&lt;/a&gt;, et kort
skydespil der bruger en voxelbaseret grafikmotor. Den vigtigste
voxel-egenskab dette spil demonstrerer er hvor relativt nemt det er at
lave spilområder som kan ødelægges - hvad der er yderst kompliceret
med polygoner er trivielt med voxels. Jeg synes selv at det er
interessant, men det er næppe overraskende at jeg er interesseret i
halvdøde og obskure teknologier der påstår at kunne gøre alting bedre
end det, der nu er mainstream.  &lt;/p&gt; 
    </description>
</item>
<item>
    <title>McCLIM 0.9.6, day of the lizardslayer</title>
    <link>http://sigkill.dk/blog/archives/304-McCLIM-0.9.6,-day-of-the-lizardslayer.html</link>

    <description>
        &lt;p&gt; McCLIM 0.9.6 &quot;St. George&#039;s day&quot; has just been released (Andy
Hefners suggestion of &quot;Discovery of the AIDS virus day&quot; was not used),
with quite a number of features. It&#039;s been over half a year since the
last release (which is unfortunately pretty typical for McCLIM), so
here&#039;s a list of the major improvements: &lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt; &lt;em&gt;Runs on SBCL:&lt;/em&gt; shortly after the McCLIM 0.9.5 release,
  the SBCL hackers cruelly removed an unexported, internal symbol that
  we relied on for some reason, preventing McCLIm 0.9.5 from running
  on anything but an oldish SBCL. ASDF-Installable McCLIM should
  therefore now run on SBCL again!&lt;/li&gt;

  &lt;li&gt;&lt;em&gt;Functions &lt;code&gt;make-pattern-from-bitmap-file&lt;/code&gt; and
  &lt;code&gt;read-bitmap-file&lt;/code&gt; added.&lt;/em&gt; These are from CLIM 2.2 and
  permit relatively simple reading of various bitmap image formats
  (currently supporting JPEG, GIF and XPM).&lt;/li&gt;

  &lt;li&gt;&lt;em&gt;Editor redisplay is much faster:&lt;/em&gt; I &lt;a
  href=&quot;http://sigkill.dk/blog/archives/297-I-can-put-what-in-my-buffer.html&quot;&gt;wrote
  a new redisplay engine&lt;/a&gt; for the Drei editor substrate a while
  back, it has &lt;em&gt;vastly&lt;/em&gt; better performance and a few extra
  features. It also improves &lt;a
  href=&quot;http://common-lisp.net/project/climacs/&quot;&gt;Climacs&lt;/a&gt; a
  lot.&lt;/li&gt;

  &lt;li&gt;&lt;em&gt;Fully in-Lisp Truetype font rendering.&lt;/em&gt; McCLIM has used
  an FFI to access &lt;a href=&quot;http://www.freetype.org/&quot;&gt;Freetype&lt;/a&gt; for
  a while, but Andy Hefner implemented a Truetype renderer in Common
  Lisp, meaning that McCLIM applications can now have pretty fonts
  without having to degrade themselves by asking C for help. Load the
  &lt;code&gt;mcclim-truetype&lt;/code&gt; system (as opposed to
  &lt;code&gt;mcclim-freetype&lt;/code&gt;) to activate it.&lt;/li&gt;

  &lt;li&gt;&lt;em&gt;Tons of bugfixes.&lt;/em&gt; As usual, this new release is the
  most stable McCLIM release ever! A lot of annoyances have been
  fixed, so McCLIM should now behave more predictably, though there is
  still some way to go before we reach perfection.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt; To celebrate this release, I hacked together &lt;a
href=&quot;http://sigkill.dk/code/tortoise.lisp&quot;&gt;a simple Logo
interpreter&lt;/a&gt;. The cool thing about this interpreter is that it
abuses &lt;code&gt;accept-from-string&lt;/code&gt; to implement a pseudo-Logo
programming language. A program can look like this: &lt;/p&gt;

&lt;pre&gt;
Pen Up
Lock
To &quot;Draw Left Half-Circle&quot;
Repeat 18
Forward 10
Left 10
Next
End
To &quot;Draw Circle&quot;
Invoke &quot;Draw Left Half-Circle&quot;
Invoke &quot;Draw Left Half-Circle&quot;
End
Unlock 
Pen Down
Center
Repeat 36
Invoke &quot;Draw Circle&quot;
Forward 20
Next
&lt;/pre&gt;

&lt;p&gt; I&#039;m not going to tell you what the output looks like, instead you
can download McCLIM 0.9.6, load &lt;a
href=&quot;http://sigkill.dk/code/tortoise.lisp&quot;&gt;tortoise.lisp&lt;/a&gt; and use
&lt;code&gt;Load Commands&lt;/code&gt; to load a file containing the above program
(or just enter it manually, if you want) and try it yourself! &lt;/p&gt; 
    </description>
</item>
<item>
    <title>Den moderne legende</title>
    <link>http://sigkill.dk/blog/archives/303-Den-moderne-legende.html</link>

    <description>
        &lt;p&gt; Danmark har endelig fået sig en rigtig helt, en ambassadør for
landet, en personificering af den danske ånd og kultur, som kan
bidrage til at fremme vores respekt i udlandet. Jeg taler naturligvis
om den fænomenale Martin, som jeg har fulgt på kanten af sædet i mange
uger under det forløb hvor han udviklede sig fra en naiv, ung mand til
den bastion af selvsikkerhed og karisma han udgør i dag.&lt;/p&gt;

&lt;p&gt;Det er måske ikke tydeligt ved første øjekast, men han er faktisk
en historisk betydningsfuld faktor i dansk kulturhistorie - man
opfatter ofte komponister som Beethoven og Mozart som altid at have
fokuseret på den aristokratiske elite, men sandheden er at &quot;klassiske&quot;
komponister blot var den tids pop-musikere - sandelig, det trak dem
mere ned end løftede dem op, at den aristokratiske overklasse forsøgte
at gøre dem til sine egne. I modsætning hertil er Martin nærmest
demokratisk valgt, fælles for hele befolkningen, og begunstiget med et
guddommeligt talent. Han har ingen af de klassiske komponisters
svagheder, men alle deres styrker, så jeg forudser at man om
århundreder vil se tilbage på 2008 som gennembrudsåret for den største
danske musiker - nogensinde.&lt;/p&gt; 
    </description>
</item>
<item>
    <title>Se South Park online!</title>
    <link>http://sigkill.dk/blog/archives/302-Se-South-Park-online!.html</link>

    <description>
        &lt;p&gt;
Måske er jeg sløv som ind i helvede, men jeg har just erfaret at man kan &lt;a href=&quot;http://www.southparkstudios.com/&quot;&gt;se alle South Park-afsnit online&lt;/a&gt;. Idet South Park, især de tidlige sæsoner, er en af de bedste serier nogensinde, har jeg allokeret de næste par dage til at genopleve den del af min opvækst, og det samme bør du.
&lt;/p&gt; 
    </description>
</item>
<item>
    <title>Dobbelt så godt!</title>
    <link>http://sigkill.dk/blog/archives/301-Dobbelt-sa-godt!.html</link>

    <description>
        &lt;p&gt; Der har været stille på denne blog i lang tid - nu vil jeg starte
op igen med hvad jeg gør bedst, nemlig at brokke mig. I dette indlæg
vil jeg kritisere vores kære statsminister, nærmere bestemt hans
seneste nærmest tragikomiske besøg hos verdens cowboy, George
W. Bush. &lt;/p&gt;

&lt;p&gt; For det første lader det til at Fogh opfatter Bush som en god
leder af den årsag at han er en &quot;flink fyr&quot; som man &quot;gerne vil drikke
en bajer med nede på værtshuset&quot; - en klassisk beskrivelse der
åbenbart ofte bruges af den menige amerikaner. Jeg ved ikke om Bush er
en sådan flink fyr, jeg ved ikke om han er god at tage på druk med -
men jeg ved at det er totalt ligegyldigt for om han er en god
statsleder, og jeg forstår ikke hvorfor det overhovedet er relevant at
snakke om den slags ting. Jeg vil &lt;em&gt;klart&lt;/em&gt; foretrække en
usympatisk, ukarismatisk stivstikker af en politikernørd, såfremt han
er kompetent, frem for et flinkt, men inkompetent, fjols. Det er
grunden til at jeg normalt godt kan tolerere Fogh som statsminister,
til trods for mine politiske uenigheder med ham.&lt;/p&gt;

&lt;p&gt; Hvad &lt;a href=&quot;http://politiken.dk/politik/article476733.ece&quot;&gt;siger
Fogh ellers?&lt;/a&gt; Vi har bl.a &lt;q&gt;verdens demokratier og verdens frie
samfund må stå sammen om at fremme demokrati og sikre
menneskerettigheder&lt;/q&gt;, samt at han åbenbart deler ideologisk
idégrundlag med Bush. Afhvad? Jeg troede Fogh var liberal? Hvad er der
liberalt ved at &lt;a
href=&quot;http://en.wikipedia.org/wiki/Habeas_corpus_in_the_United_States&quot;&gt;afskaffe
&lt;em&gt;habeas corpus&lt;/em&gt;&lt;/a&gt;? Eller hvad med det fantastiske juridiske
trick med at indespærre folk på Guantanamo-basen i årevis uden at
stille dem for en dommer - et sted der hverken er rigtig amerikansk
eller cubansk jord, og hvor ingen forfatningsgaranterede rettigheder
gælder? Vi sikrer menneskerettighederne ved at lære folk at sætte pris
på dem! Man værdsætter ikke hvad man har før man mister det!&lt;/p&gt;

&lt;p&gt; Jeg mener, jeg er ikke engang synderligt liberal, og alligevel
synes jeg den slags tricks er totalt vanvittige. I Danmark er det ikke
gået helt så galt (endnu?) - vi er stadigvæk på det punkt hvor vi blot
bruger tonsvis af penge på overvågning uden beviselig effekt,
projekter der satser mere på at skabe en følelse af tryghed end
egentlig sikkerhed. Bah, findes der overhovedet nogen lande i vesten
der ikke er blevet grebet af denne tryghedssyge? Hvorfor er de ikke i
Skandinavien? Vi skulle forestille at være et folk drevet af fornuft,
rationalitet og gensig tillid...&lt;/p&gt;
 
    </description>
</item>
<item>
    <title>Fakta</title>
    <link>http://sigkill.dk/blog/archives/300-Fakta.html</link>

    <description>
        &lt;ul&gt;
  &lt;li&gt;Stallmans kode har ikke fejl. Den definerer korrekthed.&lt;/li&gt;
  &lt;li&gt;Stallman kan afgøre om et vilkårligt program terminerer.&lt;/li&gt;
  &lt;li&gt;Stallman bruger ikke netværksprogrammer, han læser output fra
  &lt;tt&gt;tcpdump&lt;/tt&gt;. Stallman foretrækker big-endian.&lt;/li&gt;
  &lt;li&gt;Stallman kender antallet af decimaler i &amp;pi;&lt;/li&gt;
  &lt;li&gt;Stallman skriver ikke sine programmer. Han angiver blot
  et indeks i et transcendent tal.&lt;/li&gt;
  &lt;li&gt;Stallman kan skrive en kontekst-fri grammatik til C.&lt;/li&gt;
  &lt;li&gt;Stallmans computer har blot to knapper. Den ene er til
  gæster.&lt;/li&gt;
  &lt;li&gt;Stallman kender til en urettet fejl i TeX.&lt;/li&gt;
  &lt;li&gt;... og i MetaFont.&lt;/li&gt;
  &lt;li&gt;Forskellen på Gud og Richard Stallman er at Gud ikke er
  Richard Stallman.&lt;/li&gt;
&lt;/ul&gt; 
    </description>
</item>
<item>
    <title>Unusual method combinations are your friend!</title>
    <link>http://sigkill.dk/blog/archives/299-Unusual-method-combinations-are-your-friend!.html</link>

    <description>
        &lt;p&gt; Method combinations are one of the really cool, yet often
overlooked, parts of CLOS. They allow you to elegantly and succinctly
specify protocols that would otherwise require wrapper functions, ugly
calls to &lt;code&gt;call-next-method&lt;/code&gt; and a fair amount of similar
logic in every defined method. Take for instance &lt;a
href=&quot;http://common-lisp.net/project/climacs/&quot;&gt;Climacs&lt;/a&gt;, where we
have to generate a list of the available commands. This list depends
on many things, in particular the current view, syntax and active
modes, and so methods must be defined for all these. This practically
screams for an &lt;code&gt;append&lt;/code&gt; method combination, wherein every
part of an object (that is, all subclasses) get a chance to add their
own contribution to the resulting list, without any method having to
implement any kind of list-appending logic. Without method
combinations, this would have required explicit calls to
&lt;code&gt;append&lt;/code&gt; and &lt;code&gt;call-next-method&lt;/code&gt;; rote code that
is not essential to the purpose of producing a list of applicable
commands. CLOS permits me to write methods that are solely focused on
the actual task they are supposed to do, while the system takes care
of the tedious task of assembling the various results into the final
value. It also makes it trivial to add further methods later, as they
are automatically picked up by the method combination. And compared to
use of &lt;code&gt;call-next-method&lt;/code&gt;, I don&#039;t have to worry about
whether there is a next-method, CLOS takes care of that for me.&lt;/p&gt;

&lt;p&gt; This kind of functionality is, I think, what makes Lisp a powerful
language. Many other languages have syntactical shortcuts and
convenient functions for everything, enabling very short programs that
do interesting things (Ruby is particularly good at this). Common Lisp
is not well suited for one-liners and very short programs, the syntax
and provided facilities are usually too general. On the other hand,
Common Lisp shows its power once the program grows - the language
facilities are well suited for splitting up complex code and defining
small ad-hoc frameworks (like generic functions with unusual method
combinations) that would require a fair bit of code in other
languages. Thus, I believe that while Common Lisp may look overly
verbose for short programs, it makes it possible to implement long
programs in a smaller amount of code than it would take in many other
languages, and the resulting code can be flexible and extensible, even
for complex problems.&lt;/p&gt;
 
    </description>
</item>
<item>
    <title>A uniform macro for converting objects to other types</title>
    <link>http://sigkill.dk/blog/archives/298-A-uniform-macro-for-converting-objects-to-other-types.html</link>

    <description>
        &lt;p&gt; A few days ago, the great topic of #lisp was type conversion
functions, and in particular the notation that should be used for
them. Some advocated &lt;code&gt;fromtype-to-totype&lt;/code&gt;, others
&lt;code&gt;totype-from-fromtype&lt;/code&gt;, and of course perhaps the most common
notation, &lt;code&gt;fromtype-&amp;gt;totype&lt;/code&gt;. I declared that I preferred a
variant of the latter, namely &lt;code&gt;totype&amp;lt;-fromtype&lt;/code&gt;, due to the
fact that this permits clean and readable nesting, but &lt;a
href=&quot;http://www.cliki.net/Nikodemus%20Siivola&quot;&gt;Nikodemus&lt;/a&gt; of SBCL
fame pointed out that this could be turned into a more general &lt;code&gt;(&amp;lt;-
(totype middletype fromtype) object)&lt;/code&gt;-facility. And he was right,
the Power of Lisp macros, as commonly pointed out by the sublime Paul
Graham, permits all sorts of notational conveniences. I therefore set
out to write the most intuitive and clear general type conversion
facility I could think of, so that the current common practise of
writing Lisp programs as large type transformations will yield more
readable and consistent programs in the future.&lt;/p&gt;

&lt;p&gt; As my focus was on ease-of-use, an intuitive interface and
predictable semantics, I decided that the overall pattern of
&lt;code&gt;(&amp;lt;- (totype middletype fromtype) object)&lt;/code&gt; was worth
keeping. The &lt;var&gt;&amp;lt;-&lt;/var&gt; macro will rewrite this into calls like
&lt;code&gt;(totype&amp;lt;-middletype (middletype&amp;lt;-fromtype (the fromtype
object)))&lt;/code&gt; (note that &lt;var&gt;the&lt;/var&gt; is used as an optimisation
- this is the kind of thing macros allow us to do!). This means that
you just have to define a function with the name
&lt;var&gt;totype&amp;lt;-middletype&lt;/var&gt;, and then it will automatically be
used by the macro - you don&#039;t even have to export the symbol! Truly,
Paul Graham was inspired when he invented macros (and they &lt;a
href=&quot;http://docs.yahoo.com/docs/pr/release184.html&quot;&gt;certainly paid
off&lt;/a&gt;). Now you could convert types like this:&lt;/p&gt;

&lt;pre&gt;
(&amp;lt;- (integer string) &quot;123&quot;) =&gt; 123
(&amp;lt;- (integer string integer) 123) =&gt; 123
&lt;/pre&gt;

&lt;p&gt;However, I didn&#039;t feel like it was &quot;fully there&quot; yet, as you might
want to define a type conversion function like this: &lt;/p&gt;

&lt;pre&gt;
(defun integer&amp;lt;-string (string &amp;amp;optional
                        (start 0) (end (length string))
                        (radix 10))
  (values (parse-integer string :start start :end end :radix radix)))
&lt;/pre&gt;

&lt;p&gt;I think you should be able to provide values for those optional
arguments. And since I&#039;m writing a type converter, it would be
outright embarrassing if you had to provide those values directly, and
couldn&#039;t convert them from something else - and why not integrate that
directly into the single type-list (the first argument to the macro)?
That is good program design, as it clearly puts all type-specifiers in
a single place. This is now possible:&lt;/p&gt;

&lt;pre&gt;
(&amp;lt;- (integer (string integer)) 1 &quot;123&quot;) =&gt; 23
(&amp;lt;- (integer (string integer integer)) 1 2 &quot;123&quot;) =&gt; 2
(&amp;lt;- (integer (string integer integer)) 1 3 8 &quot;123&quot;) =&gt; 19
&lt;/pre&gt;

&lt;p&gt;As you may note, I decided that the arguments to the type
conversion function should go before the actual object to be
converted. This is good program design, as the overall macro works by
first saying &lt;em&gt;how&lt;/em&gt; to convert something, then providing the
actual value(s). I think the same rule should count for the values. As
an added bonus, it is now possible for machines and humans to perform
sophisticated reasoning about the macro without looking too much at
the type list, as you know things like &quot;the second through to the
second-last argument contains option values&quot; and &quot;the last argument is
the value to be converted&quot;. You may note that the &quot;real&quot; order of
types is preserved in the type list, that&#039;s because it&#039;s more logical
that way. Also, you may argue that Lisp is about freedom, and my
requirement to put parameter values first in the value-list conflicts
with that ideal; but while Lisp is indeed about freedom, putting the
value to be converted first is so plainly wrong that no-one would ever
do it, or expect it to work. Is it really loss of freedom if you
weren&#039;t going to (or weren&#039;t supposed to) do it anyway?&lt;/p&gt;

&lt;p&gt; But wait, there&#039;s more. I mentioned it would be embarrassing if
you couldn&#039;t easily type-convert the optional arguments, so of course
that was implemented too. When the type-list turns into an actual
tree, the objects to be used are retrieved from the object-list as
types are encountered in the tree during a depth-first search (and, of
course, with the above-mentioned rule about the first type in a list,
or the &quot;target type&quot;, being selected last). So you can now write
expressions like: &lt;/p&gt;

&lt;pre&gt;
(&amp;lt;- (integer (string (integer string))) &quot;1&quot; &quot;123&quot;) =&gt; 23
(&amp;lt;- (integer (string (integer string)) integer) &quot;1&quot; 123) =&gt; 23
(&amp;lt;- (integer
     (string (integer string)
             (integer (string integer integer integer)
                      integer))
     integer)
    &quot;0&quot; 0 2 2 10 123) =&gt; 12
&lt;/pre&gt;

&lt;p&gt; The final example above truly shows the power of the
&lt;var&gt;&amp;lt;-&lt;/var&gt; macro. We have (are you ready for this?) an integer,
123, that is converted to a string. This string-conversion takes
arguments, namely an integer that is converted from a string (&quot;0&quot;),
and also (this is the big one) an integer 10, that is converted to a
string, and then back into an integer starting from string offset 0,
ending at 2, and in base 2 (the result is the integer 2, of
course). Finally, the string (which is now &quot;12&quot;) is converted to an
integer, and the final result is thus the integer value 12.&lt;/p&gt;

&lt;p&gt;But of course, if you have nothing but an elegant and succinct
notation, you end up with theoretical mathematics, and I&#039;d like to
take this type conversion utility a bit further than that. Thus it is
useful to predefine a set of type conversion functions. I&#039;d like to
talk a bit about some of the more interesting of these.&lt;/p&gt;

&lt;p&gt;A very common task in modern programming is converting a bit-string
into an integer, this is done via the &lt;code&gt;bitstring&lt;/code&gt; type
(note that this is not defined as a type anywhere - it exists purely
for the function of conversion). The conversion function from
&lt;code&gt;bitstring&lt;/code&gt; reuses the &lt;code&gt;integer&amp;lt;-string&lt;/code&gt;
function, of course - code reuse is a great thing, and that it is
possible is a sure-fire symptom of excellent design:&lt;/p&gt;

&lt;pre&gt;
(defun integer&amp;lt;-binarystring (binarystring)
  (integer&amp;lt;-string binarystring 0 (length binarystring) 2))
&lt;/pre&gt;

&lt;p&gt; Another useful conversion is integers to strings - in many other
languages the null string, the string &quot;0&quot;, the string &quot;false&quot; and
others are all equivalent to the false value, while &quot;1&quot;, &quot;true&quot; and
the like are the true boolean value. I don&#039;t know why this feature
isn&#039;t part of ANSI CL, but I suspect it may have to do with lack of
time and resources on part of the standardisation group. But never
mind that - while Lisp was not the first language to get an object
system, it got the best one by far when it catched up. I was looking
for something similar with this conversion function. There is a list
of strings that are true (&quot;true&quot;, &quot;1&quot;, &quot;correct&quot;, &quot;proper&quot;, etc) and a
list of strings that are false (&quot;false&quot;, &quot;0&quot;, &quot;bad&quot;, &quot;deficient&quot;,
etc), but this alone is just slightly more comprehensive than most
other languages, not in an entirely different league, as CLOS is when
compared to other object systems. Lisp used to be an AI language, and
therefore I felt it would be highly appropriate if this conversion
function used intelligent, language-aware semantics as well as the
plain list, and thus, it handles &quot;in&quot; and &quot;not &quot;-prefixed strings,
meaning that the following useful cases work as one would intuitively
expect:&lt;/p&gt;

&lt;pre&gt;
(&amp;lt;- (boolean string) &quot;true&quot;) =&gt; T
(&amp;lt;- (boolean string) &quot;not true&quot;) =&gt; NIL
(&amp;lt;- (boolean string) &quot;not false&quot;) =&gt; T
(&amp;lt;- (boolean string) &quot;correct&quot;) =&gt; T
(&amp;lt;- (boolean string) &quot;incorrect&quot;) =&gt; NIL
(&amp;lt;- (boolean string) &quot;bad&quot;) =&gt; NIL
(&amp;lt;- (boolean string) &quot;inbad&quot;) =&gt; T
&lt;/pre&gt;

&lt;p&gt; Finally, I&#039;d like to describe the &quot;integer to boolean&quot;
conversion. Conformity with prior experiences, and the expectations
that arise from these, are important when designing intuitive
semantics, so I looked to what boolean values other languages
attribute to integers. The generally accepted pattern seemed to be
&lt;em&gt;0=false, 1=true, ...&lt;/em&gt;, so that is what I implemented:&lt;/p&gt;

&lt;pre&gt;
(defun boolean&amp;lt;-integer (integer)
  (not (zerop (mod integer 2))))
&lt;/pre&gt;

&lt;p&gt;In conclusion, I think I fulfilled my initial design goals of
intuitive semantics and a simple interface for the type conversion
utility library. The source code can be retrieved &lt;a
href=&quot;http://sigkill.dk/code/typeconv.lisp&quot;&gt;here&lt;/a&gt;, but I&#039;m going to
submit it for inclusion into &lt;a
href=&quot;http://common-lisp.net/project/alexandria/&quot;&gt;Alexandria&lt;/a&gt; in a
few days, so you hopefully won&#039;t need to manually include the file in
all your projects in the future.&lt;/p&gt;
 
    </description>
</item>
<item>
    <title>I can put *what* in my buffer?</title>
    <link>http://sigkill.dk/blog/archives/297-I-can-put-what-in-my-buffer.html</link>

    <description>
        &lt;p&gt;
&lt;em&gt;Hello, reddit! There&#039;s a link to a screenshot near the bottom, and as an extra treat, this is from my test of the new JPEG reading facilities in &lt;a href=&quot;http://common-lisp.net/project/mcclim&quot;&gt;McCLIM&lt;/a&gt;: &lt;a href=&quot;http://sigkill.dk/athas/jpegsinclimacs.png&quot;&gt;jpegsinclimacs.png&lt;/a&gt;&lt;/em&gt;
&lt;/p&gt;

&lt;p&gt; As some of you may know, &lt;a
href=&quot;http://common-lisp.net/project/climacs/&quot;&gt;Climacs&lt;/a&gt; is an
attempt at writing an Emacs-like editor in Common Lisp. This is
obviously a hard problem that requires a lot of work - I have often
been amazed at just how many exotic cases and conditions GNU Emacs
handles in even simple editing functions. It is a very mature program,
and it shows, while Climacs is still far behind Emacs in terms of
functionality and stability. &lt;/p&gt;

&lt;p&gt; But while clever editing commands and similar things aren&#039;t that
hard to implement - they mostly require time - most peoples initial
impression of Climacs has been one of very bad performance, which is
another class of problem entirely. Climacs was quite sluggish, even on
fast machines, and it&#039;s quite understandable that most people didn&#039;t
get a very good impression of a thin-featured program that was several
orders of magnitude slower than Emacs. To rectify this, I have spent
the last week and a half writing a new redisplay engine for Climacs
(specifically, the editing substrate Drei). Performance is not yet as
good as that of Emacs, nor as good as I would like it to be, but it&#039;s
&lt;em&gt;much&lt;/em&gt; faster than the old engine, and even more important, it
does not get (significantly) slower as the size of the buffer
increases, only the size of the actual displayed buffer region affects
redisplay linearly. While doing research on efficient redisplay in
text editors, I discovered that there isn&#039;t a lot of writing on doing
this on a bit-mapped display with colours - I used an &lt;a
href=&quot;http://www.cs.cmu.edu/~wjh/papers/byte.html&quot;&gt;article on the
Andrew text editor&lt;/a&gt; as initial inspiration, but it didn&#039;t cover
everything I needed to do. Therefore, I&#039;m going to write a bit about
Drei&#039;s redisplay algorithm.&lt;/p&gt;

&lt;p&gt;The redisplay engine was developed based on a key assumption: &lt;a
href=&quot;http://www.lispworks.com/documentation/lw44/CLIM/html/climguide-234.htm#pgfId-347294&quot;&gt;output
records&lt;/a&gt; are nice, flexible and useful, but they are too slow and
heavy. Hence, the redisplay engine does not use output records, except
for handling cursors and some other exotic situations. Instead, it
divides the visible region of the buffer into &lt;em&gt;strokes&lt;/em&gt;. A
stroke is a unique buffer region (does not overlap with other strokes)
that can be drawn in a single operation with a single set of drawing
options, and that does not cross lines. Put another way, a stroke is a
sequence of characters in a line with the same colour and font
(strokes can also cover non-characters, but let&#039;s ignore that for
now). The new redisplay algorithm thus works by fetching strokes from
the buffer, starting at the top of the display, and drawing them to
the screen until we reach either the end of the buffer or the bottom
of the visible part of the output sheet. When strokes are drawn, we
remember the location and size of their output.&lt;/p&gt;

&lt;p&gt;Due to the constraint that strokes cannot cross lines, we can
trivially organise strokes into lines and just check for whether a
stroke directly precedes a &lt;tt&gt;#\Newline&lt;/tt&gt; character to figure out
when we should go to the next line, and when we do this, look at the
strokes of the line and figure out the dimension of the
line. Additionally, we get the nice property, that when redisplay is
finished, no two strokes overlap.&lt;/p&gt;

&lt;p&gt;Stroke objects are kept across display, and are mutated by the
mechanism that retrieves strokes from the buffer (the stroke pump, see
below), so we can easily check whether a stroke has changed (we mark
it as &quot;dirty&quot; and &quot;modified&quot;) since the last redisplay, simply by
having the pump check whether it is going store already-existing data
in the stroke object. If a stroke is obscured for some reason (for
example due to a moving window, or part of the cursor being drawn over
it), we also mark it as dirty. Taken together, this enables
incremental redisplay, as we only redraw strokes that are dirty, and
only recalculate their size if they are modified.&lt;/p&gt;

&lt;p&gt;The interesting problem is now how to generate strokes for the
redisplay engine. This is done through two generic functions,
&lt;tt&gt;pump-state-for-offset&lt;/tt&gt; and &lt;tt&gt;stroke-pump&lt;/tt&gt;, that are used
to &quot;pump&quot; stroke data into existing stroke objects. This is both to
implement incremental redisplay, as mentioned above, and to avoid
consing (if you read the code, you&#039;ll notice that I&#039;ve been obsessed
with minimising consing in general, perhaps this was not always
necessary). For the most common case, these functions just relay to
the syntax of the view, which results in either the simple stroke
pumping defined for Fundamental Syntax, or a general parse-tree walker
defined for LR syntax that can select drawing colours based on the
actual parse symbols (wrapped in some macrology, syntax highlighting
rules can then be defined &lt;a
href=&quot;http://paste.lisp.org/display/53883&quot;&gt;like this&lt;/a&gt;). There is
nothing special about stroke pumping, except that it has to be really
fast, as it is completely non-cached and done in full for every
redisplay. All the clever caching and &quot;only handle that which has
actually changed&quot;-stuff is done at the higher level by looking at the
dirtiness of strokes, and at the lower level by the incremental syntax
parsers. The stroke pump just has to be fast, something that is most
efficiently done by connecting it closely to the parse
information. When the view is a pure &lt;tt&gt;buffer-view&lt;/tt&gt; (that is,
has no syntax) there is a simple fallback pump defined that just turns
each line into a stroke (possibly chopping it up if it&#039;s very long),
it&#039;s not fast, but it&#039;s simple, and you can look at it to get a
general idea of how it works, if you&#039;re curious. It&#039;s defined in
&lt;tt&gt;&lt;a
href=&quot;http://common-lisp.net/cgi-bin/viewcvs.cgi/mcclim/Drei/drei-redisplay.lisp?rev=1.23&amp;amp;root=mcclim&amp;amp;view=markup&quot;&gt;drei-redisplay.lisp&lt;/a&gt;&lt;/tt&gt;&lt;/p&gt;

&lt;p&gt; As an interesting special case, and as hinted at by the title of
this post, strokes do not have to cover sub-strings of the buffer. For
each stroke we have an associated set of drawing options, and in
addition to holding colour and font information, it also contains the
function to be used for drawing the stroke. Commonly, this is the
default function, which copies a string out of the buffer and prints
it with the function &lt;tt&gt;draw-text*&lt;/tt&gt;, but if a sufficient function
is provided, &lt;em&gt;any Lisp object&lt;/em&gt; can be drawn. Indeed,
Fundamental and Lisp syntax recognise non-characters in the buffer,
and create single-object strokes, with a special drawing function, for
these. This function presents the object, via CLIM, and draws the
resulting output record. This means that any Lisp object can at least
be displayed as if by &lt;tt&gt;print-object&lt;/tt&gt;, or if a CLIM presentation
method has been defined, as pretty much anything. &lt;a
href=&quot;http://sigkill.dk/athas/dreiobjects.png&quot;&gt;This screenshot&lt;/a&gt;
demonstrates the feature. Of course, stuffing the buffer full of
arbitrary objects can still fail badly in other ways, as not all
editing commands know how to deal with it. &lt;/p&gt;

&lt;p&gt;In conclusion, if you were previously put off by the poor
performance of Climacs, you should give it another try. It&#039;s not near
Emacs speed yet, but it&#039;s quite usable on modern machines, and should
improve further in the future (compared to the old redisplay engine,
the new can actually be further developed and optimised in a
straightforward way). There&#039;s also a pretty low barrier-to-entry for
hacking, and lots of low-hanging fruit still.&lt;/p&gt;
 
    </description>
</item>

</channel>
</rss>
