Luigi Auriemma

aluigi.org (ARCHIVE-ONLY FORUM!)
It is currently 19 Jul 2012 13:46

All times are UTC [ DST ]





Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 3 posts ] 
Author Message
 Post subject: miranda parsing
PostPosted: 20 Jan 2009 07:09 

Joined: 16 Jan 2009 22:16
Posts: 19
Hello, i have a question regarding the IM client Miranda. This is not concering decrypting the stored passwords, that i have already completed, here is the problem.

Passwords Stored at:
C:\Documents and Settings\<username>\Application Data\Miranda\<profilename>.dat

Inside the .dat file is the encrypted passwords amongst other things. (chatlogs, contacts, etc)

The problem i am experiencing is parsing it. I programmed something simple that puts the .dat file into the buffer and which is what i usually do when i am parsing .dat files (i either use the GetProfileString api, "bill = pwd", or a the mid function to get the text in between "<Pass> bill </pass>") How can i get the passwords for this when the .dat file is scrambled with weird characters, spaces?

In the .dat password are generally like this
Password?? "pwd" ??
or
Password?? "pwd" 
or
Many other things


~so i could simply get the text in between Password?? "pwd"  but every password has different characters at the end of the pwd so getting the text in between something and something unknown wont work.
the only common trend i see is before a password there is always "Password??"
but behind the password their is no common trend.
any ideas?

http://www.miranda-im.org/


Top
 Profile  
 
 
 Post subject: Re: miranda parsing
PostPosted: 20 Jan 2009 14:25 

Joined: 20 Jan 2009 14:13
Posts: 4
Location: Turkey
look here:
http://forums.miranda-im.org/showthread.php?t=976

//all offsets are relative to the start of the file
//offsets are 0 if there is nothing in the chain or this is the last in the
//chain

/* tree diagram

DBHeader
|-->end of file (plain offset)
|-->first contact (DBContact)
| |-->next contact (DBContact)
| | \--> ...
| |-->first settings (DBContactSettings)
| | |-->next settings (DBContactSettings)
| | | \--> ...
| | \-->module name (DBModuleName)
| \-->first/last/firstunread event
|-->user contact (DBContact)
| |-->next contact=NULL
| |-->first settings as above
| \-->first/last/firstunread event as above
\-->first module name (DBModuleName)
\-->next module name (DBModuleName)
\--> ...
*/


maybe also this can help:
miranda\plugins\db3x\encrypt.c

void Encrypt(char*msg,BOOL up)
{
int i;
int jump;
if (up)
{
jump=5;
}
else
{
jump=-5;
}

for (i=0;msg[i];i++)
{
msg[i]=msg[i]+jump;
}

}

static int EncodeString(WPARAM wParam,LPARAM lParam)
{
Encrypt((char*)lParam,TRUE);
return 0;
}

static int DecodeString(WPARAM wParam,LPARAM lParam)
{
Encrypt((char*)lParam,FALSE);
return 0;
}


Top
 Profile  
 
 Post subject: Re: miranda parsing
PostPosted: 24 Jan 2009 13:03 

Joined: 16 Jan 2009 22:16
Posts: 19
are there any examples in any language in adding the information to a temporary database? or something in that nature?


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 3 posts ] 

All times are UTC [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for: