utmp

utmp parser for node

utmp

utmp parser for node.js

$ npm install utmp 
var UtmpParser = require('utmp');
 
var p = new UtmpParser('/var/log/wtmp');
p.on('data', function(d) {
    console.log("got record:", d);
    })
 
p.run();
 
  • use ffi to read utmp definitions from libc.. don't hardcode them
  • osx/bsd support - linux only for now