By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
457,903 Members | 1,626 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 457,903 IT Pros & Developers. It's quick & easy.

how not to expose source code

P: n/a
In 1.1 I used to use a WebControlLibrary to hold code I didn't want to
expose when I distributed a component. The code would compile to a separate
dll and could not be viewed when used in a vs.net project. That worked fine
and I assume it will still work fine in 2.0.

However, in 2.0 I tried to use a simple Class library project that also
compiles to a separate dll. However when I distribute the dll, the source
code is still visible when debugging in vs.net. Am I doing something wrong
here or do class library dlls contain source code?

To do what I want to do should I continue to use the WebControlLibrary in
2.0 or is there a better alternative.

Thanks,

T
Aug 10 '06 #1
Share this Question
Share on Google+
7 Replies


P: n/a
>The code would compile to a separate
dll and could not be viewed when used in a vs.net project.
Not sure what you mean here, if the dll is available to the client, the
source code is wide open for viewing purposes. Wide open. About the best you
can do is obfuscate it and that will make it a bit more difficult to
decompile.

--
________________________
Warm regards,
Alvin Bruney [MVP ASP.NET]

[Shameless Author plug]
Professional VSTO.NET - Wrox/Wiley
The O.W.C. Black Book with .NET
www.lulu.com/owc, Amazon
Blog: http://www.msmvps.com/blogs/alvin
-------------------------------------------------------
"Tina" <Ti**********@nospamexcite.comwrote in message
news:%2****************@TK2MSFTNGP06.phx.gbl...
In 1.1 I used to use a WebControlLibrary to hold code I didn't want to
expose when I distributed a component. The code would compile to a
separate dll and could not be viewed when used in a vs.net project. That
worked fine and I assume it will still work fine in 2.0.

However, in 2.0 I tried to use a simple Class library project that also
compiles to a separate dll. However when I distribute the dll, the source
code is still visible when debugging in vs.net. Am I doing something
wrong here or do class library dlls contain source code?

To do what I want to do should I continue to use the WebControlLibrary in
2.0 or is there a better alternative.

Thanks,

T

Aug 11 '06 #2

P: n/a
A quick thought, are you sure you compiled the 2.0 version in release mode,
rather than debug?

"Tina" <Ti**********@nospamexcite.comwrote in message
news:%2****************@TK2MSFTNGP06.phx.gbl...
In 1.1 I used to use a WebControlLibrary to hold code I didn't want to
expose when I distributed a component. The code would compile to a
separate dll and could not be viewed when used in a vs.net project. That
worked fine and I assume it will still work fine in 2.0.

However, in 2.0 I tried to use a simple Class library project that also
compiles to a separate dll. However when I distribute the dll, the source
code is still visible when debugging in vs.net. Am I doing something
wrong here or do class library dlls contain source code?

To do what I want to do should I continue to use the WebControlLibrary in
2.0 or is there a better alternative.

Thanks,

T

Aug 11 '06 #3

P: n/a
Alvin:
Compiled dlls have MSIL code but not the real source code. Right?

I'm seeing the source code - comments and all. Why would a dll need the
source code?

T

"Alvin Bruney [MVP]" <www.lulu.com/owcwrote in message
news:OY**************@TK2MSFTNGP04.phx.gbl...
The code would compile to a separate
dll and could not be viewed when used in a vs.net project.
Not sure what you mean here, if the dll is available to the client, the
source code is wide open for viewing purposes. Wide open. About the best
you can do is obfuscate it and that will make it a bit more difficult to
decompile.

--
________________________
Warm regards,
Alvin Bruney [MVP ASP.NET]

[Shameless Author plug]
Professional VSTO.NET - Wrox/Wiley
The O.W.C. Black Book with .NET
www.lulu.com/owc, Amazon
Blog: http://www.msmvps.com/blogs/alvin
-------------------------------------------------------
"Tina" <Ti**********@nospamexcite.comwrote in message
news:%2****************@TK2MSFTNGP06.phx.gbl...
>In 1.1 I used to use a WebControlLibrary to hold code I didn't want to
expose when I distributed a component. The code would compile to a
separate dll and could not be viewed when used in a vs.net project. That
worked fine and I assume it will still work fine in 2.0.

However, in 2.0 I tried to use a simple Class library project that also
compiles to a separate dll. However when I distribute the dll, the
source code is still visible when debugging in vs.net. Am I doing
something wrong here or do class library dlls contain source code?

To do what I want to do should I continue to use the WebControlLibrary in
2.0 or is there a better alternative.

Thanks,

T


Aug 11 '06 #4

P: n/a
Tina,
I'm guessing that your distributed project in on the same machine as the
source file and a reference is maintained to the source because you
connected to the dll via reference. The dlls contain msil but not your real
source. Move it to another computer and try again.

However, msil exposes your code to anyone really wanting to steal your
intellectual property. A good article on this issue I found is at
http://www.aspnetpro.com/opinion/200...200208jg_o.asp .

You can always use NGen.exe if you are only going to run on Windows
platforms (duh).

See you at the meeting this afternoon.

--
Regards,
Gary Blakely
Dean Blakely & Associates
www.deanblakely.com
"Tina" <Ti**********@nospamexcite.comwrote in message
news:%2****************@TK2MSFTNGP06.phx.gbl...
In 1.1 I used to use a WebControlLibrary to hold code I didn't want to
expose when I distributed a component. The code would compile to a
separate dll and could not be viewed when used in a vs.net project. That
worked fine and I assume it will still work fine in 2.0.

However, in 2.0 I tried to use a simple Class library project that also
compiles to a separate dll. However when I distribute the dll, the source
code is still visible when debugging in vs.net. Am I doing something
wrong here or do class library dlls contain source code?

To do what I want to do should I continue to use the WebControlLibrary in
2.0 or is there a better alternative.

Thanks,

T

Aug 11 '06 #5

P: n/a
As I said, it's rather easy to take a dll and pop it into full source code
with tools like salamangar. In fact, the salamagar tool even goes as far as
showing you the original code comments along with exact variable names etc
etc.

--
________________________
Warm regards,
Alvin Bruney [MVP ASP.NET]

[Shameless Author plug]
Professional VSTO.NET - Wrox/Wiley
The O.W.C. Black Book with .NET
www.lulu.com/owc, Amazon
Blog: http://www.msmvps.com/blogs/alvin
-------------------------------------------------------
"Tina" <Ti**********@nospamexcite.comwrote in message
news:%2****************@TK2MSFTNGP04.phx.gbl...
Alvin:
Compiled dlls have MSIL code but not the real source code. Right?

I'm seeing the source code - comments and all. Why would a dll need the
source code?

T

"Alvin Bruney [MVP]" <www.lulu.com/owcwrote in message
news:OY**************@TK2MSFTNGP04.phx.gbl...
>The code would compile to a separate
dll and could not be viewed when used in a vs.net project.
Not sure what you mean here, if the dll is available to the client, the
source code is wide open for viewing purposes. Wide open. About the best
you can do is obfuscate it and that will make it a bit more difficult to
decompile.

--
________________________
Warm regards,
Alvin Bruney [MVP ASP.NET]

[Shameless Author plug]
Professional VSTO.NET - Wrox/Wiley
The O.W.C. Black Book with .NET
www.lulu.com/owc, Amazon
Blog: http://www.msmvps.com/blogs/alvin
-------------------------------------------------------
"Tina" <Ti**********@nospamexcite.comwrote in message
news:%2****************@TK2MSFTNGP06.phx.gbl...
>>In 1.1 I used to use a WebControlLibrary to hold code I didn't want to
expose when I distributed a component. The code would compile to a
separate dll and could not be viewed when used in a vs.net project.
That worked fine and I assume it will still work fine in 2.0.

However, in 2.0 I tried to use a simple Class library project that also
compiles to a separate dll. However when I distribute the dll, the
source code is still visible when debugging in vs.net. Am I doing
something wrong here or do class library dlls contain source code?

To do what I want to do should I continue to use the WebControlLibrary
in 2.0 or is there a better alternative.

Thanks,

T



Aug 12 '06 #6

P: n/a
I looked at my dll with a hex viewer. The source code is not there. The
msil is. The comments are not there.

is this a free tool?
T

"Alvin Bruney [MVP]" <www.lulu.com/owcwrote in message
news:%2****************@TK2MSFTNGP06.phx.gbl...
As I said, it's rather easy to take a dll and pop it into full source code
with tools like salamangar. In fact, the salamagar tool even goes as far
as showing you the original code comments along with exact variable names
etc etc.

--
________________________
Warm regards,
Alvin Bruney [MVP ASP.NET]

[Shameless Author plug]
Professional VSTO.NET - Wrox/Wiley
The O.W.C. Black Book with .NET
www.lulu.com/owc, Amazon
Blog: http://www.msmvps.com/blogs/alvin
-------------------------------------------------------
"Tina" <Ti**********@nospamexcite.comwrote in message
news:%2****************@TK2MSFTNGP04.phx.gbl...
>Alvin:
Compiled dlls have MSIL code but not the real source code. Right?

I'm seeing the source code - comments and all. Why would a dll need the
source code?

T

"Alvin Bruney [MVP]" <www.lulu.com/owcwrote in message
news:OY**************@TK2MSFTNGP04.phx.gbl...
>>The code would compile to a separate
dll and could not be viewed when used in a vs.net project.
Not sure what you mean here, if the dll is available to the client, the
source code is wide open for viewing purposes. Wide open. About the best
you can do is obfuscate it and that will make it a bit more difficult to
decompile.

--
________________________
Warm regards,
Alvin Bruney [MVP ASP.NET]

[Shameless Author plug]
Professional VSTO.NET - Wrox/Wiley
The O.W.C. Black Book with .NET
www.lulu.com/owc, Amazon
Blog: http://www.msmvps.com/blogs/alvin
-------------------------------------------------------
"Tina" <Ti**********@nospamexcite.comwrote in message
news:%2****************@TK2MSFTNGP06.phx.gbl.. .
In 1.1 I used to use a WebControlLibrary to hold code I didn't want to
expose when I distributed a component. The code would compile to a
separate dll and could not be viewed when used in a vs.net project.
That worked fine and I assume it will still work fine in 2.0.

However, in 2.0 I tried to use a simple Class library project that also
compiles to a separate dll. However when I distribute the dll, the
source code is still visible when debugging in vs.net. Am I doing
something wrong here or do class library dlls contain source code?

To do what I want to do should I continue to use the WebControlLibrary
in 2.0 or is there a better alternative.

Thanks,

T



Aug 14 '06 #7

P: n/a
No but you can test it here http://www.remotesoft.com/salamander/ the
results should convince you that intellectual property protection in
applications is not really possible - although the same people at the link
above claim to have an obfuscator that is bullet proof. However, at some
point in time, the cpu needs unobfuscated code to execute...

--
________________________
Warm regards,
Alvin Bruney [MVP ASP.NET]

[Shameless Author plug]
Professional VSTO.NET - Wrox/Wiley
The O.W.C. Black Book with .NET
www.lulu.com/owc, Amazon
Blog: http://www.msmvps.com/blogs/alvin
-------------------------------------------------------
"Tina" <Ti**********@nospamexcite.comwrote in message
news:O1**************@TK2MSFTNGP04.phx.gbl...
>I looked at my dll with a hex viewer. The source code is not there. The
msil is. The comments are not there.

is this a free tool?
T

"Alvin Bruney [MVP]" <www.lulu.com/owcwrote in message
news:%2****************@TK2MSFTNGP06.phx.gbl...
>As I said, it's rather easy to take a dll and pop it into full source
code with tools like salamangar. In fact, the salamagar tool even goes as
far as showing you the original code comments along with exact variable
names etc etc.

--
________________________
Warm regards,
Alvin Bruney [MVP ASP.NET]

[Shameless Author plug]
Professional VSTO.NET - Wrox/Wiley
The O.W.C. Black Book with .NET
www.lulu.com/owc, Amazon
Blog: http://www.msmvps.com/blogs/alvin
-------------------------------------------------------
"Tina" <Ti**********@nospamexcite.comwrote in message
news:%2****************@TK2MSFTNGP04.phx.gbl...
>>Alvin:
Compiled dlls have MSIL code but not the real source code. Right?

I'm seeing the source code - comments and all. Why would a dll need the
source code?

T

"Alvin Bruney [MVP]" <www.lulu.com/owcwrote in message
news:OY**************@TK2MSFTNGP04.phx.gbl...
The code would compile to a separate
dll and could not be viewed when used in a vs.net project.
Not sure what you mean here, if the dll is available to the client, the
source code is wide open for viewing purposes. Wide open. About the
best you can do is obfuscate it and that will make it a bit more
difficult to decompile.

--
________________________
Warm regards,
Alvin Bruney [MVP ASP.NET]

[Shameless Author plug]
Professional VSTO.NET - Wrox/Wiley
The O.W.C. Black Book with .NET
www.lulu.com/owc, Amazon
Blog: http://www.msmvps.com/blogs/alvin
-------------------------------------------------------
"Tina" <Ti**********@nospamexcite.comwrote in message
news:%2****************@TK2MSFTNGP06.phx.gbl. ..
In 1.1 I used to use a WebControlLibrary to hold code I didn't want to
expose when I distributed a component. The code would compile to a
separate dll and could not be viewed when used in a vs.net project.
That worked fine and I assume it will still work fine in 2.0.
>
However, in 2.0 I tried to use a simple Class library project that
also compiles to a separate dll. However when I distribute the dll,
the source code is still visible when debugging in vs.net. Am I doing
something wrong here or do class library dlls contain source code?
>
To do what I want to do should I continue to use the WebControlLibrary
in 2.0 or is there a better alternative.
>
Thanks,
>
T
>




Aug 15 '06 #8

This discussion thread is closed

Replies have been disabled for this discussion.