Work at SourceForge, help us to make it a better place! We have an immediate need for a Support Technician in our San Francisco or Denver office.

Close

Obfuscating war files

bijan
2012-01-17
2012-12-17
  • bijan
    bijan
    2012-01-17

    Hello Everybody,
    Actually I am using Proguard (ProGuard GUI) to Obfuscate my war file, but unfortunately My output war file excluded all my classes in WEB-INF folder which are necessary for my project and without them my project is unuseable.
    I should be so thankful if you give me some clue which configuration I should use to have my classes in output war file.
    Many thanks again for your cooperation,
    Regards,

     
  • Eric Lafortune
    Eric Lafortune
    2012-01-18

    Cfr. ProGuard manual > Troubleshooting > Warning: class file … unexpectedly contains class …

    You can unpack the war before processing, or put the class files in a jar in WEB-INF/lib.

    Eric

     
  • Bex_zex
    Bex_zex
    2012-02-02

    Hello Eric.

    i have same problem here. But your suggested way is not helping me.
    I can obfuscate *.ear application but there is no web services.  Other words there must be 'classes' in WEB-INF in WAR file. hope you know what i mean. But i can't see it after obfuscated and that's not all.
    I did everything you mentioned like put class files in a jar in WEB-INF/lib. of course the error occurs when i'm deploying obfuscated ear application to application server(using weblogic).

    Thanks in advice.
    Regards

     
  • somu das
    somu das
    2012-04-18

    I am in urget need.Same thing is happenig.All my class files are getting deleted from the war file when i am obfuscating it.
    Even i tried to unpack the war file by converting war to zip then unzip it.Then again just changing the file extention to war file.But in that case while obfuscation i am getting Access Denied error while obfuscation.
    Ever after obfuscation.how can we deploy the war file in jboss(Application server).Will the obfuscated war get deployed.Or we have to follow certain steps.Need help.