Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > C++ > Licensing check in a loadable .so

Reply
Thread Tools

Licensing check in a loadable .so

 
 
Sandeep Srinivasa
Guest
Posts: n/a
 
      04-07-2005
hi,
I have a software which has licensing (enabled through flexlm).
Now, an end user can build apps (As loadable modules) using this base
software.
I am introducing a new feature, which I am providing as a .so . The
development teams, release schedules, etc. are completely different
for the base software and the new .so .

1. Is it possible for me to enable licensing for the loadable .so ?

The problem is that as soon as the .so is loaded, all functions become
visible to the end-user who has a license for the base-app, but not
the .so .

I could of course use the dlopen method, but my .so has a thousand
different functions, all of which need to dlsym-ed . Rather than doing
this, I would like a check right when the .so is loaded and forget
about it later.

2. Is there a way to check for licensing in the .init section of
the .so ?

3. Will this be portable across platforms (Linux, Sun, HP 11.11) .

regards and thanks in advance
-Sandeep
 
Reply With Quote
 
 
 
 
Victor Bazarov
Guest
Posts: n/a
 
      04-07-2005
[answering in comp.lang.c++, keeping the OP's cross-post]
Sandeep Srinivasa wrote:
> hi,
> I have a software which has licensing (enabled through flexlm).
> Now, [...]


Please don't cross-post this to comp.lang.c++, it's off-topic here.
Thanks!
 
Reply With Quote
 
 
 
 
Alvin Beach
Guest
Posts: n/a
 
      04-07-2005
Sandeep Srinivasa wrote:

> hi,
> I have a software which has licensing (enabled through flexlm).
> Now, an end user can build apps (As loadable modules) using this base
> software.
>

(snip)
> 2. Is there a way to check for licensing in the .init section of
> the .so ?


This may be slightly off topic, but:

How do you access the .init section of a .so that isn't loaded by dlopen?
I'm curious because I have tend to make .so libraries for my apps[1] and
let the OS load the .so when the app starts.

I've always thought of .so files like .a (static libraries) except, the OS
just links the .so at runtime (instead of compile time).


[1] I make the libraries using -shared -fPIC switches for gcc.

--
Alvin
 
Reply With Quote
 
barts@smaalders.net
Guest
Posts: n/a
 
      04-08-2005
What do you mean by access? the init section code is run by the
dynamic linker.

For details:

http://docs.sun.com/app/docs/doc/817...section&a=view

 
Reply With Quote
 
Sandeep Srinivasa
Guest
Posts: n/a
 
      04-08-2005
I'm not entirely sure, but I guess it could be possible through the
"constructor" attribute of gcc.
-regards
SSS

Alvin Beach <reply@in_newsgroup.ca> wrote in message news:<Bac5e.6862$vt1.6616@edtnps90>...
> Sandeep Srinivasa wrote:
>
> > hi,
> > I have a software which has licensing (enabled through flexlm).
> > Now, an end user can build apps (As loadable modules) using this base
> > software.
> >

> (snip)
> > 2. Is there a way to check for licensing in the .init section of
> > the .so ?

>
> This may be slightly off topic, but:
>
> How do you access the .init section of a .so that isn't loaded by dlopen?
> I'm curious because I have tend to make .so libraries for my apps[1] and
> let the OS load the .so when the app starts.
>
> I've always thought of .so files like .a (static libraries) except, the OS
> just links the .so at runtime (instead of compile time).
>
>
> [1] I make the libraries using -shared -fPIC switches for gcc.

 
Reply With Quote
 
barts@smaalders.net
Guest
Posts: n/a
 
      04-09-2005

Jan Kandziora wrote:
> Sandeep Srinivasa schrieb:
>
> > hi,
> > I have a software which has licensing (enabled through flexlm).
> > Now, an end user can build apps (As loadable modules) using this

base
> > software.
> >

> I can't think of any software mechanism for licensing/copy protection

that
> can't easily be bypassed by any advanced programmer.
>
> You are just annoying paying customers, who will switch to a

"cracked"
> version very soon, as the don't like the whole hassle with your

licensing
> scheme. The will pay for your software, but think you are dumb - like

they
> hate Microsoft for their "product activation".
>
> Don't put too much effort into this "licensing enforcement", as it

isn't
> worth the work. There is a whole herd of people out there who will

break
> into your software just because it annoys them. You can't win.
> --
> Jan



The license check can be as difficult to disable as you like; some
folks
enjoy this game. Just make sure that the product does nothing worse
than
nag the user if he doesn't appear to have the correct license. That
way, when
their license server craps out, or they have to replace their machine
on Friday
evening before a monday deadline, your licensing check isn't the reason
they
didn't make their deadlines.

Nothing worse than having your distrust of your customer be the reason
they don't make
their quarter.

- Bart

 
Reply With Quote
 
 
 
Reply

Thread Tools

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 On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
java3d licensing: contact wanted for dev team or licensing spacewar@gmail.com Java 6 09-16-2012 01:40 AM
How to build a loadable tcl dll with visual studio (microsoft C compiler)?[crosspost in comp.lang.tcl and comp.lang.c++] Michael Reichenbach C++ 5 02-08-2010 02:38 PM
Identifying non loadable ms 98 module slowmotion Computer Support 1 10-21-2005 08:26 PM
loadable plugin architecture for g++ Jenny C++ 1 10-05-2004 11:01 PM
HTTP::Response error : "Can' t locate loadable object" Subodh Perl 0 01-07-2004 12:11 PM



Advertisments