What is meta? ×
Meta Stack Exchange is where users like you discuss bugs, features, and support issues that affect the software powering all 131 Stack Exchange communities.

I've seen a lot of posts on Stackoverflow containing decompiled source-code from the .NET framework (typically produced by a tool such as .NET Reflector). I've posted such code myself in answers, to highlight certain internal behaviours / implementation details of the framework.

Now, I recently saw such a post (from someone else) being downvoted and chastised for "showing dissembled proprietary code on a public forum like SO", and that got me slightly worried about potential legal problems. I know parts of the source-code have been released by Microsoft, but I know little about their associated licensing arrangements. In addition, it's possible that posting decompiled code is a different kettle of fish altogether.

Are there any potential legal / ethical issues here?

share|improve this question

3 Answers 3

Well the second part of that quote is

since people reading this are not allowed to contribute to ie. Mono mono-project.com/ContributinA

I'm not sure I buy that justification. It seems quibbling to me.

But the Shared Source CLI has this license. In it it has this line

You may also distribute this Software with books or other teaching materials, or publish the Software on websites, that are intended to teach the use of the Software.

I'm not a lawyer but I feel that SO falls under "teaching the use of the Software."

As for anything outside of that (using reflector to dig out code) it likely infringes on some license or law.

share|improve this answer

its not clear that people are using a decompiler.

I personally use Transcendental Meditation to look at binaries and deduce the underlying source code. is posting the deduced code illegal?

share|improve this answer
2  
The issue here isn't reversing something, it's posting the resulting code. –  Tim Post Feb 19 '11 at 11:22
    
i have edited the post accordingly. –  rbp Feb 22 '11 at 14:29
    
and thank you, because after editing i was awarded the 25 reputation points! –  rbp Feb 22 '11 at 14:31

Given that no effect has been made to stop us decompiling code from the .NET BCL, I see no problem with posting it provided:

  • It is short
  • It is needed to explain questions / answer about using the BCL (not how to write your own BCL)
  • The person posting it is not aiming to help anyone complete with the BCL

I think of post a bit of .NET BCL decompiled code on SO as being like posing a quote from a book on a website about books.

However in most cases a better answer can be given by quoting the documentation or spec.

share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .