Exetools  

Go Back   Exetools > General > General Discussion

Notices

Reply
 
Thread Tools Display Modes
  #1  
Old 02-17-2006, 14:16
Sailor_EDA Sailor_EDA is offline
Friend
 
Join Date: Nov 2004
Posts: 67
Rept. Given: 8
Rept. Rcvd 2 Times in 2 Posts
Thanks Given: 42
Thanks Rcvd at 4 Times in 2 Posts
Sailor_EDA Reputation: 2
Question Need some help on this flexlm target

Hi everybody,

I'm trying to generate a licence for a popular EDA tool that uses flexlm 9.2. In the past, I've been quite successful in recovering seeds 1 & 2 as outlined in n CrackZ's essay based on Nolan Blender's seed recovery technique i.e. place a break point on _l_sg() tracing through and examing the values of the job structure and the vendor structure.

The problem I'm facing with this particular target is that the breakpoint hits _l_sg() and the vendor structure has values in it but the job structure never gets populated, its remains exactly as it was when the breakpoint for _l_sg() hit i.e 66 followed by 0's
I can trace the rest of the flexlm routines and i can see when the features are checked out with _lc_checkout() and can see the error being set.

Going back, I traced the sequence of calls is as follows
lc_init()->_l_init()->_l_sg()

After the first _l_sg() being hit, it never hits again.

I know I'm being really sparse on information here but if anybody has anything in specific that will help, please let me know and I will post it here.

Thanks

Sailor
Reply With Quote
  #2  
Old 02-18-2006, 22:45
dirkmill dirkmill is offline
Friend
 
Join Date: Jul 2004
Posts: 23
Rept. Given: 0
Rept. Rcvd 0 Times in 0 Posts
Thanks Given: 0
Thanks Rcvd at 1 Time in 1 Post
dirkmill Reputation: 0
hi sailor!

if your main concern is getting the seeds you might want to try the following trick courtesy of crackz (hxxp://www.woodmann.com/crackz/Flexlm.htm):

Quote:
"The default value to clean the seeds variable is 3D4DA1D6h. A lot of vendors are lazy or foolish and don't change this default value. So, a very easy way is just search the pattern 3D4DA1D6h in disassembled codes. You'll get a lot of codes like this : mov [ebp-xxxx], 3D4DA1D6h. Just break on every instance containing this value and ....... run. If the program is checking the license, write down the value in [ebp-xxxx] when the first breakpoint is reached. It's your seed1 (not XORed with key5, it's original seed1). The second breakpoint you get, it's seed2. And trace a little back to the function entry, the keys (1~4) are in the parameters. Anyway, this method won't work for every case, but for beginner, it's easy to learn. ;-)."
alternatively i would recheck the structure of your dummy-license if not getting another break on _l_sg() ...

good luck to you,

dirk
Reply With Quote
  #3  
Old 02-22-2006, 14:29
Sailor_EDA Sailor_EDA is offline
Friend
 
Join Date: Nov 2004
Posts: 67
Rept. Given: 8
Rept. Rcvd 2 Times in 2 Posts
Thanks Given: 42
Thanks Rcvd at 4 Times in 2 Posts
Sailor_EDA Reputation: 2
Hi Dirkmill,

thanks for the suggestion but I already tried that. I also tried following the techniques outlined in the wondeful essay "On Software Reverse Engineering - Flexlm, IMSL".

The main problem seems to be that _l_sg() never gets called again from lc_checkout(). I think my best bet is L_UNIQ_KEY5_FUNC is getting set in lc_init() but I may not have identified the flags (as in CrackZ's Flexlm2004 essay) correctly so its doing the ecc check instead of the old style check.

Anyways, I'll keep on trying.

Thanks

Sailor
Reply With Quote
  #4  
Old 02-23-2006, 01:22
CrackZ CrackZ is offline
VIP
 
Join Date: Sep 2004
Posts: 50
Rept. Given: 2
Rept. Rcvd 66 Times in 8 Posts
Thanks Given: 0
Thanks Rcvd at 14 Times in 8 Posts
CrackZ Reputation: 67
Hiya,

The real clue here would be the value lc_checkout() actually returns, and also which version of the FLEXlm library the target uses.

I've seen a few targets recently where HOSTID=ANY is expressly rejected by a local checkout filter, alternatively it could be the format of the fake license is incorrect, either way the return from lc_checkout() should give a starting point.

Most of the targets using the Certicom routines still should call l_sg() the 2nd time, the seeds however won't be recovered. I'm sure you already knew this all anyway but if you've got something I can look at I'd be interested.

Regards

CrackZ.
Reply With Quote
  #5  
Old 02-26-2006, 03:01
Sailor_EDA Sailor_EDA is offline
Friend
 
Join Date: Nov 2004
Posts: 67
Rept. Given: 8
Rept. Rcvd 2 Times in 2 Posts
Thanks Given: 42
Thanks Rcvd at 4 Times in 2 Posts
Sailor_EDA Reputation: 2
Hi CrackZ,

I've tried playing with the license file but I don't think it is having much effect but I could be wrong. I'm playing with the default eval license that you get when you download the app from the companies site. I'll pm you the details. lc_checkout() returns 0xfffffffb which translates to "No such feature exists"
So I'm a little confused because I know the feature is used and is there in the license file.

Thanks

Sailor
Reply With Quote
  #6  
Old 02-26-2006, 16:48
toro toro is offline
VIP
 
Join Date: Aug 2004
Posts: 189
Rept. Given: 4
Rept. Rcvd 97 Times in 34 Posts
Thanks Given: 29
Thanks Rcvd at 160 Times in 51 Posts
toro Reputation: 97
hi
see my posts at
Quote:
http://forum.exetools.com/showthread.php?t=4509
i discussed a way for extarcting seeds from l_stringkey function. it can work even for v9.2
Reply With Quote
  #7  
Old 03-02-2006, 13:38
Sailor_EDA Sailor_EDA is offline
Friend
 
Join Date: Nov 2004
Posts: 67
Rept. Given: 8
Rept. Rcvd 2 Times in 2 Posts
Thanks Given: 42
Thanks Rcvd at 4 Times in 2 Posts
Sailor_EDA Reputation: 2
Hi Toro,

So I tried setting a breakpoint on _l_string_key (actually it was called l_ckout_string_key. In v9.2 sources that I have, in file, lm_ckout.c
#define l_string_key l_ckout_string_key)

However the breakpoint never hit on this function. I'm thinking there might be something wrong with my fake license at this point and thats why it may be working.

Anyways thanks for this tip, I'm sure your method will come in handy at some point in the future.

Sailor

Quote:
Originally Posted by toro
hi
see my posts at


i discussed a way for extarcting seeds from l_stringkey function. it can work even for v9.2

Last edited by Sailor_EDA; 03-03-2006 at 15:20.
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Need help with a linux flexlm target Sailor_EDA General Discussion 2 12-21-2007 20:22
Flexlm 7.2 LIC file use on Flexlm 9.2 display error -73 ? hanzi General Discussion 9 07-05-2006 18:51


All times are GMT +8. The time now is 18:08.


Always Your Best Friend: Aaron, JMI, ahmadmansoor, ZeNiX, chessgod101
( 1998 - 2024 )