Securing DLLs, Running App and AppDomain

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi:

I want to create a DLL that only can be used from applications signed with
my strong key file.

I have checked the StrongNameIdentityPermissionAttribute but it does not
work for me. So I did the next logic: When someone access the code in the
DLL, the class contained check the running application friendly name, find
the application executable, obtain its public key token and compare it with
the self public key token, if it is the same continue with the execution.

But the problem is i found applications can change its friendly name... how
can I be sure the application.exe that is running?

Or there is another way to secure who uses my dll file?
 
Carlos,
I have checked the StrongNameIdentityPermissionAttribute but it does not
work for me.

What doesn't work?

It seems to be better to figure out how to do it the supported way
than to implement your own hack.



Mattias
 
Here is the reason:

"Full demands for StrongNameIdentityPermission succeed only if all the
assemblies in the stack have the correct evidence to satisfy the demand."

I want to check only the application, we use third party dlls between the
stack, so I think my application will fail. Also, what happens with COM+,
they run under Framework DLLs with another strongName, or not?
 
Back
Top