How should I protect my code?

Hi,
To start with I'd like to apologize if I've posted this question in the wrong forum. I wasn't quite sure where to post it.
Ok, here goes. I've gotten a contract to design a database connected website for a government organization. One of the conditions of the contract is that I have to provide them with 'access' to the source code for the system I write. I haven't done a licensing agreement for the project yet, but they've already been made aware that they will receive a license and will not be allowed to use any of the source code for purposes other than expanding their system. This is fine with them. Now here's where I'm at a loss of what to do...
I know there will be future contracts awarded to continue the development of this system. However, the future contracts will be for more money and will involve less work than the orignal contract I'm doing (it's the government and they really have no comprehension of what's involved). So, I basically want to fulfill my legal obligation of providing source code, but I want to make it as difficult as possible for someone to build into the system I write. Here's what I've come up with so far.
1. Try to get a licensing agreement that forces them to obtain written permission before modifying any source code for future development (which will be necessary).
2. I've seen programs that will make code very unreadable after it's been decompiled. Is there anything that will do a similar thing to source code? For example, remove all comments and rename all the variables to something like 'an5the32'.
I know this sounds kind of greedy, but the scope of this project is considerably larger than I realized (was led to believe) and without landing one of the future contracts I'm getting ripped off, so I really have no reservations about making things difficult for them. Any suggestions would be appreciated.

Have you seen this site?
http://mindprod.com/unmainobfuscation.html
In all seriousness, there are several source code
obfuscation tools available, Just use Google and
search for "source obfuscator Java" or like.
Some of the products I found but never tested are:
http://www.semdesigns.com/Products/Formatters/Obfuscators.html
http://www.jdevelop.com/java-source-obfuscator.html
For byte code obfuscators to protect the binary from being decompiled, the links in
http://mindprod.com/jglossobfuscator.html
I found to be quite comprehensive..
BTW Out of all of them in the list,
I have evaluated Dash-O and Sourceguard.
I chose sourceguard but 4thpass chose to
abandon the product with no notice, soon
after we had bought it...
Software companies doing that kind of
thing should not last long, but anyways,
Good luck, and happy obfuscating!
Steve Tsang
[email protected]

Similar Messages

  • Due to virus attack i had to format my windows laptop...now when i installed new itunes software i had to sync my ipod touch again but it says that if do the same then the data on my ipod touch will be erased....how should i protect my ipod touch data?

    due to the virus attack i had to format my windows laptop...now when i installed new itunes software i had to sync my ipod touch again but it says that if i do it then the data present on my ipod touch will be erased as it is syncd to some older library... how should i protect my ipod touch data?

    With all you media (apps, music) in the iTunes library connect the iPod to the computer and make a backup. Do that by right clicking on the iPod under Devices in iTunes and select Back Up. Then restore the iPod from that backup.
    Note the the iPod backup that iTunes makes does not included synced media like apps and music.

  • How should I correct my code to find the mean, median & mode from an array?

    Hello everyone,
    I have been learning Java for about a month now and am stuck with the following code. There are no highlighted errors on my program when typing it into Eclipse but I get an error message when I try to run my program.
    Here is the code:
    import java.util.Random;
    * <dl>
    * <dt>Purpose:
    * <dd>Example program that randomly generates, collates and outputs numbers.
    * <dt>Description:
    * <dd>This program generates 10000 random numbers between 0 and 99 inclusive.
    * It also keeps count of how many times each number is generated and prints these
    * counts out to the screen in the format of mean, median and mode.
    * </dl> 
    * @author  Woodie Woodpeck
    * @version $Date: 2008/10/27 14:44:00 $
    public class Exercise3Point08
         public static void main(String[] args)
                   int[] counts=new int [100];
                   for(int i=0;i<100;i++)
                        counts=0;
                   Random r=new Random();
                   for(int n=0;n<10000;n++)
                        counts[r.nextInt()%100]++;
                   double sum=0.0;
                   int maxCnt=0;
                   int mode = 0;
                   int runningCount=0;
                   int median = 0;
                   for (int i=0;i<100;i++)
                        sum+=(i*counts[i]);
                        if (counts[i]>maxCnt)
                             mode=i;
                             maxCnt=counts[i];
                        if (runningCount<5000&&(runningCount+counts[i])>=5000)
                             median=i;
                        runningCount+=counts[i];
                   System.out.println("Mean =" + (sum/10000));
                   System.out.println("Median =" + median);
                   System.out.println("Mode =" + mode);
    Here is my error message:Exception in thread "main" java.lang.UnsupportedClassVersionError: Bad version number in .class file
         at java.lang.ClassLoader.defineClass1(Native Method)
         at java.lang.ClassLoader.defineClass(ClassLoader.java:620)
         at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124)
         at java.net.URLClassLoader.defineClass(URLClassLoader.java:260)
         at java.net.URLClassLoader.access$100(URLClassLoader.java:56)
         at java.net.URLClassLoader$1.run(URLClassLoader.java:195)
         at java.security.AccessController.doPrivileged(Native Method)
         at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
         at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
         at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:268)
         at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
         at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)
    And that's it. Hmmmm. Strange. I hope someone can help.
    Many Thanks
    Wood                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           

    Hi Edward,
    I moved the file from my college computer to my home computer using a USB stick and changed the workspace path on my Eclipse software to match the files that I transferred. I also cleared out a lot of random code that I had lying around my hard-drive before trying to use the code that I pasted above.
    From reading the output I guess there is a problem with the class. Do you think I might have transferred the file from one computer to another incorrectly? Do you know how I can clean and rebuild a project? Eclipse seems quite daunting and awfully complicated for a beginner!
    Thanks
    Wood

  • How should i protect accept() method from TooManyOpenFiles?

    I am calling accept() method assuming it will always work, considering it might result in NULL, but i've noticed in some situations the accept will fail and result in a CPU problem because it fails and since i did not do anything with the failure the key might still be valid and it tries to accept over and over again.
    What is the right thing to do here - should i surround with try-catch and it will not attempt to accept the connection again?
            SocketChannel channel = ((ServerSocketChannel) key.channel()).accept();
            if (channel != null)
                if (!isApprovedClient(channel))
                    channel.close();
                    channel = null;
                    rejectedClients++;
                    return;
                acceptedClients++;
                channel.configureBlocking(false);
                BasicContext context = onClientAccept(channel);
                context.setCurrentSocket(channel);
                context.setEstablishTime();
                channel.register(selector, SelectionKey.OP_READ, context);
                log.log(Level.FINER, "Added main-channel {0}", channel.socket().getInetAddress());
            }

    I am calling accept() method assuming it will always work, considering it might result in NULL, but i've noticed in some situations the accept will failFail how?
    and result in a CPU problemWhat CPU problem?
    because it fails and since i did not do anything with the failure the key might still be validWhat key? The key of the ServerSocketChannel? It is valid until you close or deregister it. Nothing to do with accept failures.
    and it tries to accept over and over again.If the accept fails there is no SocketChannel to leak/to be closed.

  • How should I protect my MBP?

    I am thinking of getting a Speck SeeThru Transparent hardshell case because I want to protect my MB from scractes and at the same time, I can still see the aluminium skin of my MB.
    But I have read a lot of reviews that it is just better to use a sleeve case for MB since the speck hardshell case add on weight and makes it more bulky.
    So if I were to buy a sleeve case for my MB, does a protector film on the macbook cover is even neccessary?
    And should I get a trackpad protector film?

    Personal Choice !
    I use Black Satin
    https://www.speckproducts.com/macbook-cases/macbook-pro-seethru-satin.html
    The Apple logo shines through, it looks smart in my opinion.
    http://www.google.co.uk/imgres?q=Black+Satin+apple+logo+speck&hl=en&sa=X&biw=129 7&bih=692&tbm=isch&prmd=imvns&tbnid=QuitjStXE93W7M:&imgrefurl=http://www.geekinh eels.com/2012/01/24/cool-tool-tuesdays-what-i-use-to-clean-and-protect-my-macboo k-pro.html&docid=33nHdnIIcBUbEM&imgurl=http://www.geekinheels.com/wp-content/upl oads/2012/01/speck_product_seethru_satin_case_apple_logo.jpeg&w=400&h=318&ei=tRi AT_6ZKqWr0QXSk_mWBw&zoom=1&iact=hc&vpx=407&vpy=154&dur=166&hovh=200&hovw=252&tx= 63&ty=147&sig=103331582394836820815&page=1&tbnh=150&tbnw=202&start=0&ndsp=15&ved =1t:429,r:1,s:0,i:69

  • How to use protected method in jsp code

    Could anyone tell me how to use protected method in jsp code ...
    I declare a Calendar class , and I want to use the isTimeSet method ,
    But if I write the code as follows ..
    ========================================================
    <%
    Calendar create_date = Calendar.getInstance();
    if (create_date.isTimeSet) System.out.println("true");
    %>
    ============================================================
    when I run this jsp , it appears the error wirtten "isTimeSet has protected access in java.util.Calendar"

    The only way to access a protected variable is to subclass.
    MyCalendar extends Calendar
    but I doubt you need to do this. If you only want to tell if a Calendar object has a time associated with it, try using
    cal.isSet( Calendar.HOUR );

  • Question  How should I react to installation Error Code:50 ?

    Question: How should I react to installation Error Code 50 ?  I'm trying to download Photoshop.

    Mlkybek are you currently installing the Creative Cloud Desktop application?  Or have you clicked on the download button as described in Install and update apps - https://helpx.adobe.com/creative-cloud/help/install-apps.html?

  • How do java software developers protect their code from their customers...

    How do java software developers protect their code from their customers, if their code can be easliy decompiled? I will really like to know how to protect my .jar archives and .class files.
    Thanks,
    RilwanJ

    That depends on what you mean by 'protect', and how paranoid you are.
    The best way is with the license, but then... it's nearly impossible to know when someone violates the license.
    You could make the source available to them for a reasonable fee (many companies won't even consider your product unless they can get the source).
    And of course if you are really paranoid, you could obfuscate it. There are a bunch of tools around to do that. But obfuscating has it's own significant set of drawbacks.
    Ultimately if you want your customers to take you seriously, you have to trust them. Onerous protection will usually cause them to look elsewhere.

  • How do I protect and embedded database from reverse engineering, hackers?

    Hello,
    I have an application that needs to be shipped to the customers with an embedded database that consists of critical application dependent data. The problem is that this data is top-secret information that for no reason should get in the hands of someone else because all the company value lies in this data. So my question is:
    How can I protect this data that are being shipped embedded in the application from hackers, reverse engineering etc? Is it even possible?
    Or is it secure enough to have the database credentials stored in the source code? Can reverse engineering get these credentials from the compiled application?

    TolvanTolvanTolvan wrote:
    Hello,
    I have an application that needs to be shipped to the customers with an embedded database that consists of critical application dependent data. The problem is that this data is top-secret information that for no reason should get in the hands of someone else because all the company value lies in this data. So my question is:
    How can I protect this data that are being shipped embedded in the application from hackers, reverse engineering etc? You can't. Regardless of the computer language being used to generate the executable it can always be reverse engineered so as to extract critical information.
    Is it even possible?No.
    >
    Or is it secure enough to have the database credentials stored in the source code? No.
    Can reverse engineering get these credentials from the compiled application?Yes.

  • Jakarta Commons FileUpload error : How should I go about it ?

    Hi fellas,
    I am using the Jakarta commons fileupload jar to write an upload servlet.
    I have created an html file where I upload a file as follows :
    <form name="upload_form" enctype="multipart-form/data" method="post" action="servlet/UploadServlet2">
    <center>
    <font face="tahoma" size="3">
    Please choose a file to upload <input type="file" name="upload_file">
    <hr>
    <input type="submit" name="bttn_submit" value="Upload File">
    </font>
    </center>
    </form>
    On posting this form, I am calling the UploadServlet which has the following code :
    import java.io.*;
    import java.util.*;
    import javax.servlet.*;
    import javax.servlet.http.*;
    import org.apache.commons.fileupload.*;
    public class UploadServlet2 extends HttpServlet
              protected void doGet(HttpServletRequest req, HttpServletResponse res) throws ServletException, IOException
                   doWork(req, res);
              protected void doPost(HttpServletRequest req, HttpServletResponse res) throws ServletException, IOException
                   doWork(req, res);
              private void doWork(HttpServletRequest req, HttpServletResponse res) throws ServletException, IOException
                   PrintWriter out = res.getWriter();
                   out.println(req.toString());
                   out.println("page loading");
                   out.println(req.getContentType());
                   out.println(req.getParameter("myText"));
                   boolean isPart = FileUpload.isMultipartContent(req);
                   out.println(isPart);
                   if(isPart)
                        out.println("is multipart");
                        DiskFileUpload upload = new DiskFileUpload();
                        try
                             List items = upload.parseRequest(req);
                             Iterator it = items.iterator();
                             while(it.hasNext())
                                  FileItem item = (FileItem)it.next();
                                  if(!(item.isFormField()))
                                       out.println("success");
                        catch (FileUploadException e)
                             // TODO Auto-generated catch block
                             System.out.println(e.getMessage());
                             out.println(e.getMessage());
                   else
                        out.println("file not received");
                   out.flush();
                   out.close();
    But the output that I get is :
    org.apache.coyote.tomcat4.CoyoteRequestFacade@7244ca page loading application/x-www-form-urlencoded null false file not received
    WHATS THAT SUPPOSED 2 MEAN ?
    Where's the mistake in my code ?
    How should I remedy the situation ?
    Help needed immediately

    Hey thanx serlank,
    I never thought I could be sooooooooooo stupid...but u c, I have Java'd so much over the last 1 year that it's now become a headache 4 me 2 spot out such small mistakes.
    But thanx 2 people like u I never can drown in the Java Ocean. U're always there in the Search-and-Rescue team...
    Hope u'll always be there...
    Well ur ego glows again...
    Thanx alot 1ce again. It works now.
    Can I have ur mail Id if u don't mind ??

  • How can I protect my data in numbers from unintentional user of my iPad by other family members? In other words, how can I password protect my numbers and other apps from apple computer company?

    I have other members of my family use my iPad for educational/recreational use, young children who may want to play kid games. I don't want them to accdently get into my data stored in the three business apps from apple. I would like to password protect these files.
    I would also like to log out of the email systems that I use, so some one else can use this device to access their own emails. By leaving my accounts open al the time, is really asking for trouble from a host of sources.
    I can't believe that the iPad is not designed to protect the privacy and data from prying eyes ... Un intuitional as it may be.
    Please fix this issue so I create my info on this device and enjoy it fully. Or tell me how I can protect my data.
    Thnax.

    Thanx for your response. Any data stored anywhere should be able to be protected from stealing, malicious destruction or unintentional destruction. Theo ad an be stolen and without any kind ofpassword protection, the thief could get into your sensitive data.
    If Apple wants iPad to become a business tool that can be used with ideas, thots, data protected, then Apple needs to provide this protection to it's customers. Now it's unto the users to use it or not.
    I know iPad is being considered to be used by doctors, and can u imagine the confidentiality requirements of HIPPA rules... It will make this device not usable without data protection. I am sureweall have heard about hacking going on at all levels. It's surprising that this device's software is left unprotected.
    My iPad may be sitting on my desk and my 3 year old grand daughter would pick it up and start "playing" with it. That means I can't store anything on this machine that may possibly be changed.
    I have discussed this with specialists in apple stores, and those who have been around info technology understand my concerns and they may forward this request further up. They do not have the answer for it..... So far.
    I think data security should be everyone's concern... Be it a one person device or multiple user device.
    I hope that some responsible people at Apple would read this and provide the protection that will make this device lot more acceptable in the business world.

  • How to Create a trigger code for turning on light bulbs in flash and animate images professional cs6

    hi,
        i designed a very interactive music website in illustrator and photoshop and i am trying to animate the main page design in flash professional and eventually publish it as HTML5. There are couple of questions i need to ask before starting
    1) should i import my design in differnet layers from illustrator into flash professional in order to make it easier to isolate and animate specific parts of the web page?
    2) i want to have a roll over effect that allows certain features in the page to turn on and off when the mouse hovers over them. can you explain how to do that? any tutorial videos i could follow
    3) what format should i use when importing my illustrator design into flash professional
    4) how should i animate the content pop out from the safe box into the main screen in flash professional (i have never used this program before, so i will be going off video tutorials and whatever suggestions/help you would have)
    **The idea is to have a content frame fly out of the safe into the screen (the size will increase rapidly and it will fade into the screen as well while rotating 360 degrees for one revolution). The content is a basic rectangular frame i designed in illustrator. The body of this frame will be transparent allowing me to embed the main page features into it eg music, videos, bio etc. All this will be done in the later process, the main issue is figuring out how to animate the content frame into the screen and also creating a click feature that allows the content to fly back into the safe and then the safe closing in.
    Secondly, the trigger code rollover effect that allows certain features light to turn on when the mouse hovers over it and turn over when its not.****

    I think you'll get most flexibility by turning on the feature that lets you keep your Illustrator layers as Flash layers. You'll also want to check the box that lets you make an Illustrator object into a MovieClip for anything that you want to interact with or address through code.
    Add an event listener for MOUSE_OVER that triggers whatever functions you need to create to turn on the features. This means that your object that you will mouse over will need to be a MC, as well as any other objects that will be addressed (for example, calling play()) will need to be a MC. You'll want to have a matching MOUSE_OUT handler that stops MC's, hides them, or whatever.
    You should probably organize your Illustrator file so that the objects you need to address are on their own layers. This includes nested objects. Name things informatively. Remember, if the first import doesn't give you exactly what you want, you don't have to save the change--you can edit your settings or the Illustrator file and try again.
    Look into motion tweens. I highly recommend the books "How to Cheat at Flash" and "Animation with Scripting." I don't really think the way they tell you to script will advance your career if you want to be a software architect, but if you just want to animate the occasional widget, it's fine.

  • I love Apple and I use all product. iPhone 3,3s,4,4s,5, iPad and Mac Air(now no more 3,3s and 4)... Only one thing I want to know is... What can I do if some one spy on my phone? How do I protect all my stuff that I put in my phone?

    I love Apple and I use all product. iPhone 3,3s,4,4s,5, iPad and Mac Air(now no more 3,3s and 4)... Only one thing I want to know is... What can I do if some one spy on my phone? How do I protect all my stuff that I put in my phone?

    the only way that anyone would be able to see anything at all on your phone is if they knew your apple id password, or they were looking over your shoulder
    if you are concerned that someone may know your apple id password, please change it at appleid.apple.com

  • How can i protect J2EE applications from piracy?

    I m looking for solution to protect Web application from piracy.
    I want my application run on web server for which it is built, &
    it musn't run on any other web server.
    how can i protect my web application from piracy?.
    Our .Net applications we protect using Hardware ID binding ,
    How can i protect J2EE applications?

    How is it going to get anywhere else? What's the threat model here? and what's the real, not imaginary, cost to you of the threat succeeding? and can you price your product such that it's cheaper to buy it than to pirate it?
    The answers to this question probably aren't in the field of tricky code or cryptography. They're more likely in marketing, time-to-market, pricing, and in physical security of the server, ...

  • RE: Typekit...how do I move the code from an old account to my new account under the Creative Cloud?

    RE: Typekit...how do I move the code from an old account to my new account under the Creative Cloud? W/out (preferably) interuption to the website in question? Thanks!

    Hi Jesse,
    Please email us at [email protected] with:
    - your current Typekit account email address
    - the email address you use for Creative Cloud
    We will be able to help you make this change without disrupting your current font serving. 
    Thank you,
    -- liz

Maybe you are looking for

  • Editing the Customer Address using Open Interface

    Hi All, The requirement is to edit the address details(postal codes) of the customer using Open Interface and not the APIs. They are insisting on using open interface as the Vertex validation(Taxation rules) is taken care only by Open Interface. Will

  • TS 140 Windows Server 2012 R2 install failure error 0x80070570

    Recently bought 2 TS140 70A4001PUX servers with Xeon E3 1245 v3 attempting to install eval version of server 2012 R2 (latest on site April refresh) and keep getting the following error at around 62% in the getting files ready for installation: Window

  • How to change the Hyper links color in the XML form

    HI SDNs Do u have any idea how to change the hyperlink color in the xml form. My requirement is as follows.I have created xml form by using xml template and i displayed this xml form by using Km document iview.  I need tochange the hyper link color i

  • How can I verify the SSL service enabled in CSS and SCA ?

    I'm working for the OpenSSL vulnerability for CSS and SCA. How can I check if the device enabled the SSL service ? - https://x.x.x.x --> cannot access. - telnet x.x.x.x 443 --> I got a blank screen. I think this should be connection rejected if no SS

  • Podcasts remaining on Ipod

    Why does my Ipod now keep heard podcasts on the display screen? Used to be that when I listened to a podcast it was removed and only unheard ones were left. Recently this changed and all remain after syncing. Any ideas? Thanks