A side note: both jbackup.pl and my script require an environment that can execute perl code and some added modules. If this doesn't make sense to you or if you don't have access to such a thing, I'm sorry but you can't play :( I've thought about this at length and there's no good way that I can securely make this available to people who can't run it themselves. Perhaps someone can reimplement it for Windows or Mac or in Java or something, but I don't have the skillz for that. I thought about doing a web service but one way or the other you'd have to hand your journal over to me and that's no good. So if you can't run it yourself, you're SOL for now.
For jbackup.pl, you'll need the following modules:
- XMLRPC::Lite - Part of the SOAP::Lite package
I'm not sure what the best way to get jbackup.pl is. I know it's in the LiveJournal CVS. You can get it thusly:
cvs -d :pserver:email@example.com:/home/cvslj login cvs -d :pserver:firstname.lastname@example.org:/home/cvslj co livejournal/src/jbackup/jbackup.plenter an empty password after the login step. Or you can download this file.
In order to use it, you must first backup your journal using jbackup.pl:
./jbackup.pl --sync Username: exampleusername Password:Then a bunch of text will scroll by. Once it's done, run my script:
./ljgroupanalyze.pl -j exampleusername Enter your password:After entering your password, output similar to the following will appear:
+------------+ | some group | +------------+ http://www.livejournal.com/users/exampleusername/14438.html http://www.livejournal.com/users/exampleusername/15262.html +---------------+ | another group | +---------------+ http://www.livejournal.com/users/exampleusername/14847.html http://www.livejournal.com/users/exampleusername/15262.html +-------------+ | third group | +-------------+ http://www.livejournal.com/users/exampleusername/14854.htmlNote that one post (15262.html) is in both Some Group and Another Group. It supports complex filtering! Amazing!
I'm sure many of you are wondering why it requires your password. The reason is simple: it phones home to the server to fetch the names of your friends groups. That's all. If you look at the code, you'll see that the only place the password is used is in generating the response segment of a challenge/response handshake for authentication while downloading the group names.
It should be noted that jbackup.pl was written by the LiveJournal staff (marksmith, to be specific) and you shouldn't worry that it asks for your password. Besides, it's backing up your journal... how else would it work? :)
If you're uncomfortable giving your password to my script, there's another option... though you should be warned it's a bit less useful. You can invoke the script with
--simple, and all you'll get is a list of posts with their associated allowmask:
16 -- http://www.livejournal.com/users/bleything/14847.html 32 -- http://www.livejournal.com/users/bleything/14854.html 24 -- http://www.livejournal.com/users/bleything/15262.html 8 -- http://www.livejournal.com/users/bleything/14438.htmlThe numbers represent the allowmask of the post... you see, each friends group has a particular bit, and permission to view a post is determined by ANDing that mask with the blah blah blah. See, it's not as useful. But it's there for the paranoid.
There are two ways to get the code. The first (and best!) is to check it out of my subversion repository. If you have svn installed, you can do so by issuing the following command:
svn co http://svn.bleything.net/toys/ljgroupanalyzer
This way you can keep up-to-date as I add new features. Another good way is to just fetch this URL. That'll always be up-to-date as well. If there's demand, I can put together a distribution tarball or .zip or something.
If you identify issues with the code, please feel free to either comment here or (preferred!) open a ticket here. Make sure you select ljgroupanalyzer as the component!
I also welcome all other comments or questions. Thanks for checking it out :)