Invalid or COrrupt JAR file

I have one jar file of java classfiles created in eclipse. Its working fine with eclipse after giving Run Configuration (main class).
But when I try to run jar file from command prompt its giving me error - ' Invalid or corrupt jar file'
I have edited Manifest.mf for adding Main-Class also.
I have also checked in Tools-->folder option-->File Types-->Selecting Jar-->Advanced-->Edit and given the correct path of javaw.exe like - "D:\SDP75\jdk\bin\javaw.exe" -jar "%1" %*. The same jdk used for compling the classes.
Please help me. I have done volumes of googling for this. This is very crtytical to me.
Thanks

802387 wrote:
Its working fine with eclipse after giving Run Configuration (main class).So it works if you just run the main class.
>
But when I try to run jar file from command prompt its giving me error - ' Invalid or corrupt jar file'
But it doesn't when you attempt to run it as an executable jar.
I have edited Manifest.mf for adding Main-Class also.
As a guess that is the problem. You messed up that file.
Or you are not running the same thing in both cases.

Similar Messages

  • Corrupt .jar files

    Hi All,
    We are trying to deploy JDeveloper for OAFramework through patch 4573517.
    After extracting, we are facing errors for initiating OC4J instance due to corrupt .jar files.
    So if any one is having the listed .jar files for JDeveloper OAF compatible, kindly mail on [email protected]
    .jar files
    aolj.jar
    classes111.jar
    classes12.jar
    flex.jar
    oamdsct.jar
    ojdbc14.jar
    portalFlexComps.jar
    regexp.jar
    sax2.jar
    share.jar
    uix2.jar
    xmlparserv2.jar
    Thanks in Advance
    Sachin

    It didn't work, but I can reach sites that I have a link to on my Desktop. I haven't had Mozilla Firefox very long and I don't even remember what should appear when I select it. Any other thoughts? I appreciate your reply irregardless. At least I am now backed up with a new restore point. Many thanks bens545

  • What do I do about a corrupt jar file at C:/Program Files (x86)/MozillaFirefox/omni.jar!/chrome/browser/content/browser/places/content-ui/controller.xhtml.

    Mozilla Firefox is my default browser, but the page doesn't load and I get the message that Mozilla can't find the file at Jar file. I was told to check the file name for capitalization or other typing errors. Then check to see if the file was moved, renamed or deleted. When I checked the file, I was told that it was corrupt. I use Mozilla Thunderbird and I don't want to do anything to jeopardize my e-mail and address book, etc.

    It didn't work, but I can reach sites that I have a link to on my Desktop. I haven't had Mozilla Firefox very long and I don't even remember what should appear when I select it. Any other thoughts? I appreciate your reply irregardless. At least I am now backed up with a new restore point. Many thanks bens545

  • Invalid binary - corrupted png file

    I've tried three times now to update my app that is already on the app store. Every time I loaded the new binary, about a minute later it was rejected. I then get this email response:
    Corrupt Icon File - The icon file [email protected] appears to be corrupt.
    Can somebody please help me out with this if you have seen the samething?
    Thanks

    OK, after attempting a million different fixes nothing worked until...
    I did a google search for corrupt pngs and invalid binaries. I came across a post about some kind of bug in xcode 4.3.1 that compresses pngs which causes the invalid binary message. So, on this hunch I resaved all my pngs without compression and PROBLEM SOLVED!
    If anybody else has a similar problem this seems to be the root.

  • Dumping Firefox 4 due to constantly corrupted jar file

    Firefox can't find the file at jar:file:///C:/Program Files (x86)/Mozilla Firefox/omni.jar!/browserconfig.properties.

    Start Firefox in <u>[[Safe Mode]]</u> to check if one of the extensions is causing the problem (switch to the DEFAULT theme: Firefox (Tools) > Add-ons > Appearance/Themes).
    * Don't make any changes on the Safe mode start window.
    * https://support.mozilla.com/kb/Safe+Mode
    * https://support.mozilla.com/kb/Troubleshooting+extensions+and+themes
    See also:
    * http://kb.mozillazine.org/Preferences_not_saved

  • Jar file Corrupted

    Hi
    I created an exe for a jar file using Xenoage.
    The exe file executes fine in normal conditions.
    I used a license manager for my software.
    The input file for the license manager is the exe
    file created by Xenoage.
    The output file obtained is in an unrecognised format. When
    i execute the file using java the error that i get is
    Invalid or corrupt jar file+
    What could be the reason for the jar file to be corrupt.
    with Regards
    A.Rajesh

    >
    I have auser that gets the following error message when he tries to launch my application through Java web start:
    An error occured while launching/running the application.
    Corrupted JAR file at http://javadl.sun.com/webapps/javawsautodl/AutoDL/j2se/javaws-1_0_1-j2re-1_6_0-inst-windows-i586.jar>
    That URL is a 404, it does not exist. Where did it come from? Your JNLP file?
    Speaking of which, where is your JNLP file (URL or content)?
    >
    I have asked to perform the following operations but without any success:
    - re-install the JRE
    - clear the cache of the JWS applications>How about changing the cache location entirely? I describe how on the last post of this thread.
    <http://forum.java.sun.com/thread.jspa?threadID=5209499>
    >
    He gets exactly the same message when trying to execute:
    javaws.exe -viewer >Same deal when launching the player?
    <http://java.sun.com/products/javawebstart/apps/player.jnlp>

  • Create a jar file

    Hello everybody! :) I really need your help.
    I have Tom.class
    I want to create a jar file.
    I use eclipse, so I created jar file there. I got MarkTven.jar in which:
    Tom.class
    .project
    .classpath
    MATA-INF / MANIFEST.MFin MANIFEST.MF:
    Manifest-Version: 1.0
    Main-Class: Tomclicking at MarkTven.jar I get:
    Invalid or corrupted jar file.Help me please.
    Message was edited by: ghost:))

    I have to say, that although this has nothing to do with me, I'd like to pass some comment. This attitude is prevalent throughout the forums and how can people be expected to gain experience if their efforts will be down-played and you try to make them accountable for their ignorance? It's a contradiction in terms. This is a large forum with more than a lifetimes worth of reading for those of us with a life.
    America70 has given you all the information you require to develop a resolve. I think he/she was depending on you perhaps being aware of a common issue he/she may have overlooked. I would treat that as misplaced respect personally, however, you could have steered him/her towards passing you further detail of his/her issue so that the issue could be resolved. Instead, this query remains, pointlessly, filling up space and uselessly guiding other new leaners no-where.
    You guys may be offering your advice for 'free' but you are also advocates for the language in doing so. Surely you should be making greater efforts to promote the language instead of forcing people to steer clear of attempting to expand their knowledge? It's just an opinion...
    *free - I use this term loosely because the cost to the learner is far from free, the expense being the mentors ego.
    In reference to the above post, America70 had simply made a typo in his/her query to you, not mis-spelt it in his/her implementation; he/she explained that. If he/she is required to add more detail, then politely ask him/her to. America70 also pointed out that he/she had followed the tutorial. It is obvious he/she has mis-read, mis-understood, or badly-impemented something. He/she has obviously overlooked this and is unable to discover the fault. It's not rocket science. If you people can't positively add to this post then what is your use as a helper/teacher?
    Edited by: chewzLife on May 18, 2008 7:50 PM
    Edited by: chewzLife on May 18, 2008 7:51 PM

  • Deleting file from .jar file

    I m having trouble with the Forum search, so sorry if this question has been answered before in this forum.
    If I create a .jar (or an .ear) file, then open the file using Winzip and then delete a file from the zip, does it corrupt the .jar file? I ran into such a problem recently where I could not deploy the application because the .ear file still contained references to the deleted file.

    No, Winzip doesn't corrupt jar files. But if you have something else that expects to find X in the jar file and you deleted X, it isn't surprising that problems arise.

  • Authentication issue when downloading jar files

    Hi,
    I am having a problem starting up my application when the application server, in this case WebSphere 5.0, requires the user to be authorized.
    In our development environment the server uses basic authentication but once deployed in our test environment we are required to use form based authentication, which I've read that JWS cannot handle.
    The current flow is as follows:-
    1. The user navigates to a protected page and is prompted to enter a user name and password.
    2. Once authenticated they are shown the page that contains a link to a JNLP file.
    3. The user clicks on the link, JWS processes the JNLP file and requests the first jar file.
    4. The application server sees that there is no 'authorization' header set on the request so asks for the credentials again.
    5. For basic authentication the user is prompted by JWS to enter the user name and password and the download succeeds.
    6. For form based authentication, JWS instead receives an HTML login page and, after a short period, reports that it received a corrupted jar file.
    I was wondering if there is any way to pass key/value pairs within the JNLP file (or any other approach to pass this data) that JWS could then use to populate the 'authorization' header of the request to load the jar files?
    If this is not possible, are there any other techniques I could use to get round this?
    I am currently passing other data via the 'JSP as JNLP' approach with my own servlet so can make dynamic changes to the JNLP file as needed.
    Thanks in advance.

    Hi ipooley,
    I came upon your posting here after I've been searching for long for some "standard-conform" decision to this IMHO very popular problem and I was not able to find something so far apart of adding some jsessionid to the jar files in the href tag in order to hack the app server to believe the client is authenticated. In my case this doesn't help as well because the authentication is done separately through the company portal. Could you please give me some more details about your "hack"? I've tried to call the jnlp file from an applet (simply with showDocument(jsp generating jnlp) but this doesn't (and actually it can't) work too. And what about the jnlp file itself - if I set the href in the jnlp I have the same problems with the jnlp too?
    thanks in advance for your reply,
    Ilko

  • Corrupt Jar from Signtool 1.3

    I have been signing applets successfully for months using Signtool.exe and Winows NT4. I recently switched to Win2k, and now signtool.exe is producing corrupt jar files. I can still go to another PC running NT4 and successfully sign the file.
    After running signtool.exe under Win2k, I get the message that the tree was signed successfully. However, if I try to verify that the appplet is signed correctly using the -w option of signtool, it tells me
    NOTE -- "classes.jar" archive DID NOT PASS crypto verification. (reported reasonL Corrupt JAR file)
    Using WinZip to open the jar, I get a message like this:
    error: expected central file header signature not foud (file #2)
    Cannot open file: it does not appear to be a valid archive.
    If you downlaoded this file, try downloading the file again.
    Has anyone else had any problems with signtool under Win2k? Does anyone know of any workarounds for this?

    More info: I have successfully imported my Netscape signing certificate from VeriSign into Netscape 4.7, and am pointing signtool to the correct directory to see the key3.db file.

  • Corrupted ojdbc14.jar file

    I have twice attempted to download the latest version of the Oracle JDBC drivers. Both times, the files seem to be corrupt.
    Attempting to examine the ojdbc14.jar file contents with the following command:
    jar tvf ojdbc14.jar
    leads to the following error message:
    java.util.zip.ZipException: incomplete literal/length tree
    Attempting to examine the ojdbc14_g.jar file contents with the following command:
    jar tvf ojdbc14_g.jar
    leads to the following error message:
    java.util.zip.ZipException: invalid stored block lengths
    Attempting to read either file with EnZip utility program gives the following errors:
    Warning - Error in Zip structure
    A central header signature is wrong
    Can anyone tell me how to get around these errors?
    Dave Eland
    [email protected]

    Well. On the third try, it worked OK. The first two times, I was using Netscape to access the web site, and the third time I had switched to Internet Explorer.
    This is the first time I have seen this phenomena. Whatever was causing the file corruption seems to have been resolved.

  • Artifact harvest failed due to: Unexpected error import: Invalid jar file

    Hi,
    i am trying to submit the .biz and .proxy file to OER using Eclipse,
    but i am getting the following error,
    can anybody help me on it,
    what i am missing ?
    8332 [Main Thread] INFO com.bea.alsb.harvester.plugin.reader.OSBReader - OSB Config Jar Import / Validation starting.
    <Mar 13, 2012 10:28:16 AM IST> <Warning> <ConfigFwk> <BEA-000000> <Setting transaction '6' as rollback only. Rollback reason:
    java.io.IOException: Invalid jar file
    at com.bea.wli.config.importexport.ConfigJar$LogicalJarForm.<init>(ConfigJar.java:1341)
    at com.bea.wli.config.task.impl.UploadJarTask._execute(UploadJarTask.java:46)
    at com.bea.wli.config.task.impl.SessionedTask$1.execute(SessionedTask.java:233)
    at com.bea.wli.config.transaction.TransactionalTask._doExecute(TransactionalTask.java:217)
    at com.bea.wli.config.transaction.TransactionalTask._doExecuteWithRetry(TransactionalTask.java:162)
    at com.bea.wli.config.transaction.TransactionalTask.doExecute(TransactionalTask.java:142)
    at com.bea.wli.config.task.impl.SessionedTask.doExecute(SessionedTask.java:236)
    at com.bea.wli.config.task.impl.SessionedTask.doExecute(SessionedTask.java:191)
    at com.bea.wli.config.task.impl.UploadJarTask.uploadJar(UploadJarTask.java:36)
    at com.bea.wli.config.mbeans.Config.uploadJarFile(Config.java:442)
    at com.bea.alsb.harvester.utils.ConfigJarUtils.importConfigJar(ConfigJarUtils.java:79)
    at com.bea.alsb.harvester.plugin.reader.OSBReader.readQuery(OSBReader.java:196)
    at com.bea.alsb.harvester.plugin.reader.OSBReader.readQueries(OSBReader.java:112)
    at com.bea.alsb.harvester.plugin.reader.OSBReader.read(OSBReader.java:87)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at com.flashline.util.classloader.ContextClassLoaderHandler.invoke(ContextClassLoaderHandler.java:39)
    at $Proxy0.read(Unknown Source)
    at com.oracle.oer.sync.framework.MetadataManager.start(MetadataManager.java:630)
    at com.oracle.oer.sync.framework.Introspector.<init>(Introspector.java:204)
    at com.oracle.oer.sync.framework.Introspector.main(Introspector.java:430)
    8426 [Main Thread] ERROR com.oracle.oer.sync.framework.MetadataManager - Artifact harvest failed due to: Unexpected error import: Invalid jar file
    com.oracle.oer.sync.framework.MetadataIntrospectionException: Unexpected error import: Invalid jar file
    at com.bea.alsb.harvester.utils.ConfigJarUtils.importConfigJar(ConfigJarUtils.java:97)
    at com.bea.alsb.harvester.plugin.reader.OSBReader.readQuery(OSBReader.java:194)
    at com.bea.alsb.harvester.plugin.reader.OSBReader.readQueries(OSBReader.java:112)
    at com.bea.alsb.harvester.plugin.reader.OSBReader.read(OSBReader.java:87)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at com.flashline.util.classloader.ContextClassLoaderHandler.invoke(ContextClassLoaderHandler.java:39)
    at $Proxy0.read(Unknown Source)
    at com.oracle.oer.sync.framework.MetadataManager.start(MetadataManager.java:630)
    at com.oracle.oer.sync.framework.Introspector.<init>(Introspector.java:204)
    at com.oracle.oer.sync.framework.Introspector.main(Introspector.java:430)
    Caused by: java.io.IOException: Invalid jar file
    at com.bea.wli.config.importexport.ConfigJar$LogicalJarForm.<init>(ConfigJar.java:1341)
    at com.bea.wli.config.task.impl.UploadJarTask._execute(UploadJarTask.java:46)
    at com.bea.wli.config.task.impl.SessionedTask$1.execute(SessionedTask.java:233)
    at com.bea.wli.config.transaction.TransactionalTask._doExecute(TransactionalTask.java:217)
    at com.bea.wli.config.transaction.TransactionalTask._doExecuteWithRetry(TransactionalTask.java:162)
    at com.bea.wli.config.transaction.TransactionalTask.doExecute(TransactionalTask.java:142)
    at com.bea.wli.config.task.impl.SessionedTask.doExecute(SessionedTask.java:236)
    at com.bea.wli.config.task.impl.SessionedTask.doExecute(SessionedTask.java:191)
    at com.bea.wli.config.task.impl.UploadJarTask.uploadJar(UploadJarTask.java:36)
    at com.bea.wli.config.mbeans.Config.uploadJarFile(Config.java:442)
    at com.bea.alsb.harvester.utils.ConfigJarUtils.importConfigJar(ConfigJarUtils.java:79)
    at com.bea.alsb.harvester.plugin.reader.OSBReader.readQuery(OSBReader.java:196)
    ... 11 more
    Please help...
    Regards,
    yogesh

    Hi Yogesh - when you say "i don't think the file is corrupt, because it works fine in eclipse", do you mean, you are actually able to publish them to a server and test those out?
    Dont know your exact scenario, but when you say that you took the sbconfig from another machine and used it on your local system, cant we just go ahead with that? I mean, clean up your code base, and then import this latest "working" sbconfig and start afresh?
    -Swagat

  • "Invalid or corrupt file" after Obfuscation with "The Marvin Obfuscator"

    Hi!
    I want to use "The Marvin Obfuscator" (www.drjava.de) to secure MY code a little bit.
    But the resulting .jar-file doesn't work. "Invalid or corrupt file".
    I think, that things, i configured in the configuration file aren't true.
    Has anyone experience with "The Marvin Obfuscator"?
    I created a .jar-file with Eclipse. My Marvin-configuration-file (config.txt) is as the following:
    // Template for a Marvin Obfuscator config file
    // Directories and jar/zip archives where your application's classes reside
    // (relative to project directory)
    classpath=("archive.jar","C:\Java\jre1.5.0_05\lib\rt.jar")
    // The name of your applet or applications's main class
    // (e.g. executable class, servlet or applet)
    // (as it would appear in <applet code=...> or in "java ...")
    // Note the double parentheses!
    mainClasses=(("control.Start"))
    // If you want your main class to be called differently after the obfuscation,
    // you can enter the new name (including package) like this:
    // mainClasses=(("myapp.Main" newName="main"))
    // You can also have more than one main class:
    // mainClasses=(("myapp.ServletA") ("myapp.ServletB"))
    // Names of methods (without class name) that are accessed via reflection.
    // The obfuscator will not change the names of these methods.
    //preserveMethodNames=("methodName1","methodName2","reflected*")
    // Classes that are accessed via reflection.
    // The obfuscator will not change the names of these classes.
    // Note: Method names within these classes will still be obfuscated.
    // (If you need to preserve method names too, what you probably want
    // is "externalClasses".)
    // Note: You can use the wildcard character (*).
    //preserveClassNames=("mypackage.SpecialClass")
    // Classes that are used by your application,
    // but should not be included in the obfuscated jar file.
    // The obfuscator also ensures that references to these classes continue to
    // work ("referencing" includes calling, subclassing and implementing).
    // Note: Any part of these libraries that is actually used must be in the
    // classpath (either system classpath or classpath= line in this file).
    //externalClasses=("com.company.externallibary.*","org.apache.*")
    // Locations of resource files.
    // If you want resource files (images, properties files, ...) to be included
    // in the jar file, specify the resource directories or archives here.
    // Do NOT specify individual resources files (these will be interpreted as
    // archives).
    // Note: Directories will be scanned recursively.
    // Note: .class files are excluded automatically.
    // Note: You will usually want to reuse entries from the classpath= line
    // (classes and resources are often bundled in the same jar files).
    //resources=("resourcedir","resources.jar")
    // Advanced obfuscation features.
    encryptStrings=true // You can try to set this to false for troubleshooting

    Why not use another obfuscator? Google for "java obfuscator". I myself
    use JShrink and it does a good job in reducing the code size.
    It always generated valid class files for me.
    As for "protection", don't count on it too much with any obfuscator, but
    yes, some may do a better job than others.

  • I own a website and my customers download zipped files. Until yesterday everything worked great. All of the sudden they are getting a message that the file is invalid or corrupt. This does not happen in Chrome.

    I own a website selling digital files. My customers receive an email after they place their order with a download link. Up until yesterday (for the past 3 years to be exact) everything worked smoothly. I have not changed one thing on my site or cpanel. Now customers get an error that the file is invalid or corrupt when they try and download with firefox. The links work fine with chrome. Please tell me there is a solution. This is causing major trouble!!!

    You can get a "Corrupted Content Error" error if there are multiple location redirects send via the HTTP response headers.
    *http://www.mozilla.org/security/announce/2011/mfsa2011-39.html
    *[https://bugzilla.mozilla.org/show_bug.cgi?id=681140 bug 681140] - Corrupted Content error due to multiple Content-Disposition header field instances
    A good place to ask advice about web development is at the mozillaZine Web Development/Standards Evangelism forum.<br />
    The helpers at that forum are more knowledgeable about web development issues.<br />
    You need to register at the mozillaZine forum site in order to post at that forum.<br />
    See http://forums.mozillazine.org/viewforum.php?f=25

  • WDS Server 2012 R2 "The specified image file is either invalid or corrupted"

    Hi,
    I'm trying to setup a WDS in a 2012 R2 environment but I cannot add install image for x64 architecture.
    I've managed to add boot images from both x86 and x64 architecture and install image for Windows 8.1 x86.
    For everything else I receive the error message "The specified image file is either invalid or corrupted". The images used for setting up the install are 100% functional (I manualy installed the OS from them).
    I tried to unconfigure, reconfigure, reinstall role, install on another machine, everything without success.
    Thanks!

    Hi Costache Cristi,
    What account you are using when you meet this issue, please use the
     domain administrator permission account   to import image or please try give your image source everyone full control permission then monitor again, it seems is the permission issue.
    More information:
    Windows Deployment Services 101
    https://technet.microsoft.com/en-us/magazine/2008.08.desktopfiles.aspx
    I’m glad to be of help to you!
    Please remember to mark the replies as answers if they help and unmark them if they provide no help. If you have feedback for TechNet Support, contact [email protected]

Maybe you are looking for

  • Oracle.xml.parser.v2.XMLParseException: Invalid char in text. in BPEL

    Hi, Non Recoverable Business Fault : <bpelFault><faultType>1</faultType><operationErroredFault xmlns="http://xmlns.oracle.com/bpel/workflow/taskService"><part name="payload"><operationErroredFault xmlns="http://xmlns.oracle.com/bpel/workflow/taskServ

  • [RPC Fault faultString="HTTP/1.1 415 Unsupported Media Type" faultCode="Server.Proxy.Request.Failed"

    Hi, Posting in the 'General' forums as well. Did not yet get any response for the topic posted in the 'Configuration and Getting Started Discussion' forum. I am having nightmares to call the POST method of a REST service thru Flex. Initially tried wi

  • Nano 2gb 2nd gen. wont turn on????????????

    Wont turn on even with full battery, it turns on after i disconnect it from my laptop but for some reason i wont respond after a few hours of it being off. could this be a software problem if it turns on after being connected to a power source but wo

  • XML data (image and accompanying filename)?

    Hi, I just recently viewed some video tuts and read some Flex material so I'm a little more comfortable with all of its syntaxes and such. However one thing that eludes me when I tried to do this on my own was calling an XML file in mxml and having F

  • ABAP Training required in mogappair, Chennai - India

    Hi Guru's,                I am looking for a ABAP trainer with a genuine real time knowledge, kindly suggest me the best place or person to learn ABAP in and around mogappair area, chennai - India. Also if any one interested in taking the class, kind