<?xml version="1.0"?>
<rss version="2.0">
  <channel>
    <title>Advogato blog for ingvar</title>
    <link>http://www.advogato.org/person/ingvar/</link>
    <description>Advogato blog for ingvar</description>
    <language>en-us</language>
    <generator>mod_virgule</generator>
    <pubDate>Thu, 23 May 2013 05:14:57 GMT</pubDate>
    <item>
      <pubDate>Thu, 26 Apr 2012 19:13:31 GMT</pubDate>
      <title>26 Apr 2012</title>
      <link>http://www.advogato.org/person/ingvar/diary.html?start=314</link>
      <guid>http://www.advogato.org/person/ingvar/diary.html?start=314</guid>
      <description>Eeeeerf. Not much code written in my spare time. And a crashed server. And a very long time since I posted at all. I am, however, alive and may actually get around to purchase new hardware, one of these days.</description>
    </item>
    <item>
      <pubDate>Wed, 24 Nov 2010 09:27:14 GMT</pubDate>
      <title>24 Nov 2010</title>
      <link>http://www.advogato.org/person/ingvar/diary.html?start=313</link>
      <guid>http://www.advogato.org/person/ingvar/diary.html?start=313</guid>
      <description>Long while of not posting. Nothing (much) programming-&#xD;
related to mention, but...&#xD;
&#xD;
&lt;p&gt; New job. Turns out I am not emigrating right at the moment &#xD;
(bit of a last-minute surprise, there, as it happens). New &#xD;
employer seems to be a sensible multi-national corp, though.&#xD;
&#xD;
&lt;p&gt; Managed to score a (small) writing contract. That reminds &#xD;
me, need to poke the editor-in-chief that I haven't seen &#xD;
the paper copies of the contract yet. The task is to write &#xD;
an article about the BESK machine, a piece of hardware I &#xD;
have only seen the console of, but it is nonetheless a &#xD;
machine that warms the cockles of my heart.&#xD;
&#xD;
&lt;p&gt; Also noticed that there's been a bit of movement in the &#xD;
SHA1-cracking. Apparently Amazon EC2 GPU instances are real &#xD;
good for SHA1-based password hashes. I don't know, exactly, &#xD;
what this means for SHA1-based HMACs, but I am pretty sure &#xD;
it's not entirely pleasant. So, need to go back to the &#xD;
drawing board and switch out SHA1 and switch in something &#xD;
else for NOCtool's network protocol.</description>
    </item>
    <item>
      <pubDate>Wed, 25 Aug 2010 08:50:53 GMT</pubDate>
      <title>25 Aug 2010</title>
      <link>http://www.advogato.org/person/ingvar/diary.html?start=312</link>
      <guid>http://www.advogato.org/person/ingvar/diary.html?start=312</guid>
      <description>Not managed to poke code, as such, but I've checked (one of) &#xD;
the monitored variables (ifOutOctets on the ethernet port of &#xD;
a router at home). Next step is to write some more methods on &#xD;
the SHOW gf, to generate prettier graphs (background, grid, &#xD;
some text, that sort of thing).&#xD;
&#xD;
&lt;p&gt; Would probably need to add a selector-thing to allow easy &#xD;
graphing of each of the things monitored, but taht's but a &#xD;
keyword away.</description>
    </item>
    <item>
      <pubDate>Tue, 24 Aug 2010 10:49:02 GMT</pubDate>
      <title>24 Aug 2010</title>
      <link>http://www.advogato.org/person/ingvar/diary.html?start=311</link>
      <guid>http://www.advogato.org/person/ingvar/diary.html?start=311</guid>
      <description>Hm, there's some odd interaction between Swank and the &#xD;
existing NOCTool ping monitors. Nonetheless, there's now SNMP &#xD;
monitoring of a single network device running. Howpefully, &#xD;
I'll get a chance to poke around in the code tonight or &#xD;
tomorrow morning, to see if it's actually doing anything &#xD;
interesting.</description>
    </item>
    <item>
      <pubDate>Fri, 20 Aug 2010 10:29:55 GMT</pubDate>
      <title>20 Aug 2010</title>
      <link>http://www.advogato.org/person/ingvar/diary.html?start=310</link>
      <guid>http://www.advogato.org/person/ingvar/diary.html?start=310</guid>
      <description>So, back to poking at the &lt;a href="http://common-lisp.net/&#xD;
project/noctool/" &gt;NOCTool&lt;/a&gt; codebase again. This time, &#xD;
the intent is to get some SNMP support into it, to more &#xD;
easily be able to monitor routers and switches. There's &#xD;
also some opportunity to monitor server hosts via SNMP, but &#xD;
at the moment unix-based hosts can be adequately monitored &#xD;
via SSH.&#xD;
&#xD;
&lt;p&gt; First, I created a class for "things monitored by &#xD;
SNMP" (with curucial details like community strings and &#xD;
SNMP version in it, plus slots for anything we're &#xD;
monitoring via SNMP; this is currently just interfaces). &#xD;
Then, an SNMP configuration stanza for the config reader. &#xD;
Inside the SNMP stanza, configuration stanzas for anything &#xD;
monitored by SNMP (again, just interfaces at the moment). &#xD;
&#xD;
&lt;p&gt; The intent is to let an empty interface spec is to mean &#xD;
"auto-discover all interfaces, then monitor them" and for &#xD;
anyone wanting a subset, simply naming the interfaces.&#xD;
&#xD;
&lt;p&gt; The actual monitoring starts with an snmp-walk of the &#xD;
ifTable.ifEntry.ifDescr sub-tree, mapping names to current &#xD;
SNMP indexes, then passing the resulting hash table down to &#xD;
each "get stuff for this specific interface" function &#xD;
(taking the current SNMP session, mapping table and &#xD;
interface object as arguments).&#xD;
&#xD;
&lt;p&gt; So far, I am happy with what I have, but it's yet to be &#xD;
used in anger.</description>
    </item>
    <item>
      <pubDate>Thu, 8 Jul 2010 09:23:52 GMT</pubDate>
      <title>8 Jul 2010</title>
      <link>http://www.advogato.org/person/ingvar/diary.html?start=309</link>
      <guid>http://www.advogato.org/person/ingvar/diary.html?start=309</guid>
      <description>I was reading &lt;a href="http://www.advogato.org/person/titus/" &gt;titus&lt;/a&gt;'s recent &lt;a href="http://www.advogato.org/person/titus/&#xD;
diary/458.html" &gt;post about data structures for k-mer &#xD;
filtering&lt;/a&gt;.&#xD;
&#xD;
&lt;p&gt; ONe thing struct me. Titus, you looked at binary Bloom &#xD;
filters, but seemingly ignored Counting Bloom filters &#xD;
(where instead of indexing a bit with your hashes, you &#xD;
index a counter of a suitable size, you do run into &#xD;
problems if you need both increments and decrements, since &#xD;
once you it max on the counter, you can no longer &#xD;
decrement).&#xD;
&#xD;
&lt;p&gt; Of course, it's not necessarily trivial going from a Bloom &#xD;
filter (counting or not) to the key, whereas the key is &#xD;
typically available when using a normal hash table.&#xD;
&#xD;
&lt;p&gt; I suspect, but have not verified, that a counting Bloom &#xD;
combined with the parallelization opportunity you found &#xD;
(and that one is the big win, I think) would be an equally &#xD;
interesting approach.</description>
    </item>
    <item>
      <pubDate>Fri, 19 Feb 2010 10:08:08 GMT</pubDate>
      <title>19 Feb 2010</title>
      <link>http://www.advogato.org/person/ingvar/diary.html?start=308</link>
      <guid>http://www.advogato.org/person/ingvar/diary.html?start=308</guid>
      <description>This morning, I finished off and packaged up a library (CL, &#xD;
linux; other OSes with CL implementations and OS-provided &#xD;
random (or random-backed pseudorandom) devices can probably &#xD;
be grafted in, but would require volunteers to test) to &#xD;
extract random bits from &lt;tt&gt;/dev/urandom&lt;/tt&gt; and use &#xD;
those essentially unadorned to generate random numbers.&#xD;
&#xD;
&lt;p&gt; There's a single exported function from the package, &#xD;
RANDOMNESS:RND and takes an integer argument (I guess you &#xD;
could try feeding it a float, but it wouldn't do you that &#xD;
much good). That function then proceeds to extract &#xD;
log&lt;sub&gt;2&lt;/sub&gt; N bits and uses rejection smapling to find &#xD;
an integer in the 0..(N-1) span. As the bits sucked out of &#xD;
the internal  pool run out (each bit is used only the &#xD;
once), they're replenished from the OS-provided randomness &#xD;
source.&#xD;
&#xD;
&lt;p&gt; All very nice, with some interesting corner cases for the &#xD;
unwary and probably still bug-ridden. But, such is life.&#xD;
&#xD;
&lt;p&gt; Download &lt;a href="http://src.hexapodia.net/&#xD;
randomness.tar.gz" &gt;from here&lt;/a&gt;.</description>
    </item>
    <item>
      <pubDate>Thu, 3 Dec 2009 11:58:51 GMT</pubDate>
      <title>3 Dec 2009</title>
      <link>http://www.advogato.org/person/ingvar/diary.html?start=307</link>
      <guid>http://www.advogato.org/person/ingvar/diary.html?start=307</guid>
      <description>Neat(ish) hack...&#xD;
&#xD;
&lt;p&gt; Sometimes, I find myself writing anonymous functions, to &#xD;
fill out keyword arguments for functions or adapting the &#xD;
argument order. So, I thought, how hard would it be to &#xD;
write a macro to write the code for me? Turns out, not very &#xD;
complex, at all. The formatting is not QUITE what I started &#xD;
out with, as the Advogato edit box is a bit on the short &#xD;
end, but, hey...&#xD;
&#xD;
&lt;p&gt; &lt;pre&gt;&#xD;
(defmacro _ (form)&#xD;
 (flet ((is-arg (sym)&#xD;
	  (ignore-errors&#xD;
	   (and (char= (char (symbol-name sym) 0) #\_)&#xD;
		(cons&#xD;
		 (parse-integer (symbol-name sym)&#xD;
				:start 1)&#xD;
		 sym)))))&#xD;
   (let ((syms (loop for arg in form&#xD;
		  for temp = (is-arg arg)&#xD;
		  if temp collect temp)))&#xD;
    `(lambda&#xD;
	 ,(mapcar #'cdr (sort syms #'&amp;lt; :key #'car))&#xD;
       ,form))))&#xD;
&lt;/pre&gt;&#xD;
&#xD;
&lt;p&gt; With this in hand, you can, for example, easily make an &#xD;
adapter to parse C-style hex constants:&#xD;
&lt;pre&gt;&#xD;
  (_ (parse-integer _1 :radix 16 :start 2))&#xD;
&lt;/pre&gt;&#xD;
&#xD;
&lt;p&gt; Not that the lambda-wrapping of this would've been much &#xD;
more complex and I am not entirely sure this wins as far as &#xD;
readability is concerned, but that is as it may be. It's if &#xD;
nothing else a neat macro that would be more than a little &#xD;
tricky to pull off with a less capable macro facility.</description>
    </item>
    <item>
      <pubDate>Fri, 27 Nov 2009 08:19:54 GMT</pubDate>
      <title>27 Nov 2009</title>
      <link>http://www.advogato.org/person/ingvar/diary.html?start=306</link>
      <guid>http://www.advogato.org/person/ingvar/diary.html?start=306</guid>
      <description>So, one of the users of my &lt;a href="http://&#xD;
src.hexapodia.net/image.tar,gz" &gt;Image library&lt;/a&gt; asked if &#xD;
there wasn't any way of using a font other than the rather &#xD;
ugly, built-in one. I said, roughly, "you can define a new &#xD;
one, in an analogous fashion to how the built-in oine is &#xD;
done?"&#xD;
&#xD;
&lt;p&gt; Apparently, that was not the wished-for answer and I &#xD;
started thinking. Bit-mapped fonts are (relatively) easy to &#xD;
deal with. There's a helluva lot of bitmapped fonts for &#xD;
X11. So, I set forth to code up a reader for PCF fonts, &#xD;
converting the bitmaps to internal format and some multi-&#xD;
font support in Image. All done, now.&#xD;
&#xD;
&lt;p&gt; Common Lisp is still very pleasant when dealing with binary &#xD;
file I/O, even if I wished that there was an easy way of &#xD;
changing the binaryness of a file on the fly.</description>
    </item>
    <item>
      <pubDate>Wed, 18 Nov 2009 09:53:52 GMT</pubDate>
      <title>18 Nov 2009</title>
      <link>http://www.advogato.org/person/ingvar/diary.html?start=305</link>
      <guid>http://www.advogato.org/person/ingvar/diary.html?start=305</guid>
      <description>Currently tooling away at asked-for functionality for my &#xD;
IMAGE library (specifically, a request was made to see if I &#xD;
can scare up another font or three, so I am currently &#xD;
noodling on a PCF font-file reader, as you do).&#xD;
&#xD;
&lt;p&gt; Common Lisp continues to be amazingly convenient for &#xD;
"binary I/O", although it does require a certain mind-set &#xD;
to consider it convenient, I guess.</description>
    </item>
  </channel>
</rss>
