Thx,
I have come up a very simple perl script for the printing of the history
file. Hope it can help others too.
Alan.
On Wed, 14 Aug 2002, <DeXteR> wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> Alan Tai wrote:
> | thx...but what is the other numbers for?
> |
> | [ S | 0001 | 0270 | 0000 | 1029328960 ]
> |
> | I konw 'S' is for send and 'R' is for receive..
> | but in the above case, what does '0001', '0270' and '0000' means?
> |
>
>
>
> 0001 = SubCommand = What kind of message is it
> HEX = DEC = Description
>
> 0x0001 = 0001 = Message
> 0x0002 = 0002 = Chat
> 0x0003 = 0003 = File
> 0x0004 = 0004 = URL
> 0x0006 = 0006 = Auth Request
> 0x0007 = 0007 = Auth REFUSED
> 0x0008 = 0008 = AUTH GRANTED
> 0x0009 = 0009 = Message throug server
> 0x000C = 0012 = Added to contact list
> 0x000D = 0013 = Web Panel
> 0x000E = 0014 = Email Pager
> 0x0013 = 0019 = Contact List
> 0x001A = 0016 = SMS
> 0x001A = 0016 = ICBM??? (note from source "This one secks")
> 0x8000 = 32768= Multiple Recepists (WTF???)
> // Encryption stuff
> 0x00ED = 0237 = Old Securetty (Or something like it)
> 0x00EE = 0238 = Secure channel closed
> 0x00EF = 0239 = Secure Channel opened
>
> 0270 = Command = TCP commands
> This is weird, didn't get the point, its not used in qts history source...
>
> 0000 = Some flags (with i allso haven't figured out)
>
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.0.7 (GNU/Linux)
>
> iD8DBQE9Wo+J8my61PfbPIIRAvOuAKCMkQx2og+rp/xp3HiySDnfUIKKbACffImd
> J75i/RrgJ5dMK5KDBJIBEL0=
> =kYqP
> -----END PGP SIGNATURE-----
>
>
>
> -------------------------------------------------------
> This sf.net email is sponsored by: Dice - The leading online job board
> for high-tech professionals. Search and apply for tech jobs today!
> http://seeker.dice.com/seeker.epl?rel_code=31
> _______________________________________________
> Licq-main mailing list
> [EMAIL PROTECTED]
> https://lists.sourceforge.net/lists/listinfo/licq-main
>
--
Alan Tai
=========================================
System Analyst
Top Pine Technology Ltd.
Tel: 2760 8819
Fax: 2760 9189
#!/usr/bin/perl
#use strict;
if (!$ARGV[0] || !$ARGV[1] || !$ARGV[2]) {
print "Please enter filename to trasform!\n";
print "synax: <file> <receiver> <sender>\n";
exit();
}
#my $time = localtime(1029328960);
#print $time."\n";
#format =
#^<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
#$d;
#~~ ^<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
# $string;
#
#.
format =
^<<<<<<<< ^<<<<<<<<<<<<<<<<<<<<<<<<< ^<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
$name, $d, $string
.
#$d = "[Alan]:";
#$string = "I love joyce so much that I don't want to lose her!";
open(IN,$ARGV[0]) or die "Error! Open file $ARGV[0] failed!";
$i=0;
$line = <IN>;
$ch = substr($line,0,1);
$d = substr($line,1,length($line)-2);
$head = $line;
#while (($line = <IN>) && ($i < 10)) {
while ($line = <IN>) {
$i++;
#print $line;
$ch = substr($line,0,1);
if ($ch eq "[") {
$d = substr($head,2,length($head)-4);
@tmp = split(' \| ',$d);
$d = localtime($tmp[4]).":";
# print "$tmp[0]\n";
if ($tmp[0] eq 'R') {
#$d = "[".$ARGV[1]."] ".localtime($tmp[4]).":";
$name = "[".$ARGV[2]."] ";
} else {
#$d = "[".$ARGV[2]."] ".localtime($tmp[4]).":";
$name = "[".$ARGV[1]."] ";
}
$head = $line;
$string = $string;
write while ($string);
$string = "";
} else {
$string .= substr($line,1,length($line))." ";
}
}
close IN;