Invalid CEN header ( bad signature )

I get this reeor when I try to import .par file in NWS.
invalid CEN header ( bad signature )
also say that The Plugin "com.sap.portal.plugins.config-archiver" caused an exception during the unpack opreation

Hello! experts,
I got the same error but i manage to solve it.
While trying to import the par file, please ensure the 'Project root folder' is giving correctly.
In my case, when i got the error, the folder i initially selected was not there.
Check if the Project folder you are selecting is there or folder is read / write.
This will solve your problem.
Thanks!
Regards,
Kishore
*Please reward points if this solution works for you*

Similar Messages

  • Jarsigner: invalid END header (bad central directory offset)

    I signed a jar (which is a standalone application) with:
    C:\>jarsigner -keystore myKeystore myJar.jar
    I verified it with
    C:\>jarsigner -verbose -verify myJar.jar
    It was OK.
    I updloaded it to my web site via ftp.
    When I try to to downlod it via Java Web Start, I get a java.util.zip.ZipException.
    If I try to verify it again with jarsigner, I get:
    jarsigner: java.util.zip.ZipException: invalid END header (bad central directory offset).
    Can anyone tell me where the jar file may have been corrupted ?
    Thanks a lot
    Norberto

    You were right, John.
    Thanks a lot.
    I hope to help you one day.
    Norberto:
    Did you remember to ftp myJar.jar in binary mode? As
    I recall, ftp assumes things are ASCII files and does
    funny things to the file if it is actually a binary.
    A good way to check this, I would think would
    calculate the MD5 hash of your signed Jar file just
    after you have signed it and then again on the other
    end after you've FTPed it with "md5sum myJar.jar" (or
    whatever the windows equivalent is, if applicable).
    At least that would be where I'd start to look for
    something that "messed up" your jar file.
    Good luck,
    John

  • Invalid stream header exception

    hi all
    I have a program to encrypt/decrypt a file using existing secret key
    which is generated by my java code and it works fine. I got a key from a friend and an encrypted file to decrypt it but the program throws this exception:
    java.io.StreamCorruptedException: invalid stream header: 87449FAA
    Exception in thread "main" java.security.InvalidKeyException: No
    installed provider supports this key: (null) this is my code:
    try
        //throws exception here
        ObjectInputStream in = new ObjectInputStream(new
    FileInputStream("key.dat"));
        key = (SecretKey)in.readObject();
        byte[] raw = key.getEncoded();
        skeySpec = new SecretKeySpec(raw, "AES");
        in.close();
    catch (Exception e)
        System.out.println(e);
    Cipher cipher = Cipher.getInstance("AES");
    cipher.init(Cipher.DECRYPT_MODE, skeySpec); Honestly i don't know how my friend creates the secret key but i think he uses some key generation tools. I suppose the key file is not corrupted because he used it to encrypt/decrypt other files.

    Looks like your friend did not use Java serialization to save the key in the file.
    Edited by: sabre150 on Apr 13, 2008 5:27 PM

  • Invalid stream header Exception - AES PBE with SealedObject

    I am trying to do an PBE encryption with AES algorithm and SunJCE provider, using the SealedObject class to encrypt/decrypt the data...
    And Im still getting the "invalid stream header" exception. Ive searched this forum, readed lots of posts, examples etc...
    Here is my code for encryption (i collected it from more classes, so hopefully I didnt forget anything...):
        //assume that INPUT_STREAM is the source of plaintext
        //and OUTPUT_STREAM is the stream to save the ciphertext data to
        char[] pass; //assume initialized password
        SecureRandom r = new SecureRandom();
        byte[] salt = new byte[20];
        r.nextBytes(salt);
        SecretKeyFactory factory = SecretKeyFactory.getInstance("PBKDF2WithHmacSHA1");
        KeySpec keySpec = new PBEKeySpec(pass, salt, 1536, 128);
        SecretKey pbKey = factory.generateSecret(keySpec);
        SecretKeySpec key = new SecretKeySpec(pbKey.getEncoded(), "AES");
        Cipher ciph = Cipher.getInstance("AES/CTR/NoPadding");
        ciph.init(Cipher.ENCRYPT_MODE, key);
        ByteArrayOutputStream byteOut = new ByteArrayOutputStream();
        int ch;
        while ((ch = INPUT_STREAM.read()) >= 0) {
          byteOut.write(ch);
        SealedObject sealed = new SealedObject(byteOut.toByteArray(), ciph);
        BufferedOutputStream bufOut = new BufferedOutputStream(OUTPUTSTREAM);
        ObjectOutputStream objOut = new ObjectOutputStream(bufOut);   
        objOut.writeObject(sealed);
        objOut.close();
      }And here is my code for decrypting:
        //assume that INPUT_STREAM is the source of ciphertext
        //and OUTPUT_STREAM is the stream to save the plaintext data to
        char[] pass; //assume initialized password
        SecureRandom r = new SecureRandom();
        byte[] salt = new byte[20];
        r.nextBytes(salt);
        SecretKeyFactory factory = SecretKeyFactory.getInstance("PBKDF2WithHmacSHA1");
        KeySpec keySpec = new PBEKeySpec(pass, salt, 1536, 128);
        SecretKey pbKey = factory.generateSecret(keySpec);
        SecretKeySpec key = new SecretKeySpec(pbKey.getEncoded(), "AES");
        BufferedInputStream bufIn = new BufferedInputStream(INPUT_STREAM);    //MARK #1
        ObjectInputStream objIn = new ObjectInputStream(bufIn);   
        SealedObject sealed = (SealedObject) objIn.readObject();   
        byte[] unsealed = (byte[]) sealed.getObject(key);          //MARK #2
        ByteArrayInputStream byteIn = new ByteArrayInputStream(unsealed);
        int ch;
        while ((ch = byteIn.read()) >= 0) {
          OUTPUT_STREAM.write(ch);
        OUTPUT_STREAM.close();Everytime I run it, it gives me this exception:
    Exception in thread "main" java.io.StreamCorruptedException: invalid stream header: B559ADBE
         at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:783)
         at java.io.ObjectInputStream.<init>(ObjectInputStream.java:280)
         at javax.crypto.SunJCE_i.<init>(DashoA13*..)
         at javax.crypto.SealedObject.unseal(DashoA13*..)
         at javax.crypto.SealedObject.getObject(DashoA13*..)
         at oopsifrovanie.engine.ItemToCrypt.decrypt(ItemToCrypt.java:91)  //MARKED AS #2
         at oopsifrovanie.Main.main(Main.java:37)    //The class with all code below MARK #1I've also found out that the hashCode of the generated "key" object in the decrypting routine is not the same as the hashCode of the "key" object in the ecrypting routine. Can this be a problem? I assume that maybe yes... but don't know what to do...
    When I delete the r.nextBytes(salt); from both routines, the hashCodes are the same, but that's not the thing I want to do...
    I think, that the source of problem can be this part of code (generating the key):
        SecretKeyFactory factory = SecretKeyFactory.getInstance("PBKDF2WithHmacSHA1");
        KeySpec keySpec = new PBEKeySpec(pass, salt, 1536, 128);
        SecretKey pbKey = factory.generateSecret(keySpec);
        SecretKeySpec key = new SecretKeySpec(pbKey.getEncoded(), "AES");But I derived it from posts like: [http://forums.sun.com/thread.jspa?threadID=5307763] and [http://stackoverflow.com/questions/992019/java-256bit-aes-encryption] and they claimed it's working there...
    Is there anyone that can help me?
    Btw, I don't want to use any other providers like Bouncycastle etc. and I want to use PBE with AES and also SealedObject to store the parameters of encryption...

    Yes, it really uses only one Cipher object, but it does decoding in a little nonstandard (not often used) way, by using the SealedObject class and its getObject(Key key) method. You can check these links for documentation: [http://java.sun.com/javase/6/docs/technotes/guides/security/crypto/CryptoSpec.html#SealedObject] and [http://java.sun.com/javase/6/docs/api/javax/crypto/SealedObject.html] So the question is, why it doesn't work also with the AES routines, because it should.
    Btw, according to [http://java.sun.com/javase/6/docs/technotes/guides/security/SunProviders.html#SunJCEProvider] PBEWithSHA1AndDESede/CBC/PKCS5Padding is a valid JCE algorithm for the Cipher class.
    Firstly, I was generating the key for AES enc./decryption this way and it was working:
    char[] pass; //assume initialized password
    byte[] bpass = new byte[pass.length];
        for (int i = 0; i < pass.length; i++) {
          bpass[i] = (byte) pass;
    SecretKeySpec key = new SecretKeySpec(bpass, "AES");
    But I think, that it really wasn't secure, so I wanted to build a key from the password using the PBE.
    Maybe there's also a way how to do this part of my AES PBE algorithm: *KeySpec keySpec = new PBEKeySpec(pass, salt, 1536, 128);* manually (with my own algorithm), but I dont know how to do it and I'd like it to be really secure.
    Btw, thanks for your will to help.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

  • Bad Signature on Mac OS 10.5.8 Update

    I have a Mac G5 running Mac OS X 10.5.6.
    Want to update to 10.5.8 using the software update mechanism. It downloads the 768MB file but then cannot install it because it has a bad signature (indicating that it may have been tempered with). Anybody know a place to get a good version?
    Related:
    I upgraded to iTunes 9, but now cannot get to the iTunes Store, as that requires at Safari 4.0.3 or later. I downloaded Safari 4.0.3, but that cannot be installed because it requires Mac OS X 10.5.7 or newer. And the upgrade to the new OS does not work because of the bad signature. I wish I had stayed on the old version of iTunes .

    Thank you, that download installed without a problem. It also installed Safari 4.0.2, which still had to be upgraded to 4.0.3. Now iTunes 9 is happy and can access the iTunes store, so I can get my Podcasts again.
    Life is good.
    Thanks,
    Mark

  • LWAPP"invalid IP header checksum"

    Hello , i hace a problem with a wireless network based on 4 WiSM (two in two 6500) and AP1010. AP's get IP from the DHCP and associate to the controller, but after a while, they start sending a syslog message LWAPP-ERROR: "invalid IP header checksum". I have ping losses and the AP dissasociates, reloads and reassociates to the controller. Does anyone have found the same problem?
    thanks

    What code are you running on the WLC's? I know that with the AP1010, you can't be running the newer code. that is why I ask.
    Is this happening on all 4 WLC's and can you post a snip of the log from the cli.

  • Xorg fails with "/usr/lib/libexpat.so.1: invalid ELF header"

    After upgrade, Xorg fails with the following message:
    (EE) AIGLX error: dlopen of usr/lib/xorg/modules/dri/i965_dri.so failed (/usr/lib/libexpat.so.1: invalid ELF header)
    (EE) AIGLX: reverting to software rendering
    openbox: error while loading shared libraries: /usr/lib/libexpat.so.1: invalid ELF header
    (I also get en error about fbcon, fbdev modules, but have read that this is not actually an issue.)
    Thanks for any help.
    Last edited by marimo (2010-01-24 07:12:25)

    If it were different architectures, there would be an ELF class error. Assuming that all of the installed libraries are from the Arch repos, I'm betting that expat is corrupt. I would reinstall expat and see if that solves the problem.

  • Problem: Invalid BTree Header

    I don't use 9.2.2 much but could it be a problem for 10.4.7? on 9.2.2 I get: Problem: Invalid BTree Header all the time after running Disk first aid again and again. It says it fixed the problem but the error keeps comming back.
    I know this has been disscussed elsewhere but I could not find a definite answer on what to do. I will not use Norton. Please help.
    W.W.

    Hi Walter;
    If DW can touch the problem, about the only solution left is to reformat and reinstall now.
    One question, you did run DW while booted from another disk? If not, DW is not able to repair the disk that the operating system is running from.
    Allan

  • Getting "java.io.StreamCorruptedException: invalid stream header"

    When creating a self made Stream (MacInputStream) and then using an ObjectInputStream over it to read Objects from a socket, I get this error:
    java.io.StreamCorruptedException: invalid stream header
         at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:764)
         at java.io.ObjectInputStream.<init>(ObjectInputStream.java:277)
         at TServidor.run(TServidor.java:32)
    Is there any special feature that the "self-made" streams have to implement to be possible to use ObjectInput streams over them :P ?
    Here is the MacInputStream.java code:
    import java.io.Closeable;
    import java.io.FilterInputStream;
    import java.io.IOException;
    import java.io.InputStream;
    import java.util.Arrays;
    import javax.crypto.Mac;
    public class MacInputStream extends FilterInputStream implements Closeable{
         private Mac mac; // algorithm
         private byte [] mmac; //message MAC
         private boolean FIRST_TIME;
         public MacInputStream(InputStream is,Mac mac) {
              super(is);
              this.mac=mac;
              FIRST_TIME=true;
    public int read() throws IOException{
              if(FIRST_TIME){
                   mmac = new byte [mac.getMacLength()];
                   super.read(mmac);
              if(super.in.available()==0){
                   FIRST_TIME=true;
                   return -1;
              int rbyte = super.in.read();
              FIRST_TIME=false;
              mac.update((byte)rbyte);
              System.out.println("available: "+super.in.available());          
              if(super.in.available()==0){
                   byte [] macres =mac.doFinal();
                   System.out.println("message MAC: "+new String(mmac));
                   System.out.println("calculated MAC: "+new String(macres));
                   if(!Arrays.equals(macres, mmac)){
                        throw new IOException("violated integrity");
              return rbyte;
    public int read(byte [] b) throws IOException{
         if(FIRST_TIME){
              mmac = new byte [mac.getMacLength()];
              super.in.read(mmac);          
         if(super.available()==0){
              FIRST_TIME=true;
              return -1;
         int rbytes = super.in.read(b);
         FIRST_TIME=false;
         mac.update(b);
         if(super.available()==0){
              byte [] macres =mac.doFinal();
              if(!Arrays.equals(macres, mmac)){
                   throw new IOException("violated integrity");
         return rbytes;
    }And here is the "main" function where the exception gets thrown:
    public void run() {
         try {
              ObjectOutputStream oos = new ObjectOutputStream(s.getOutputStream());
              Mac mac = Mac.getInstance("HmacMD5");
              Key key = KeyGenerator.getInstance("HmacMD5").generateKey();          
              oos.writeObject(key);
              oos.flush();
              mac.init(key);          
              ObjectInputStream cis = new ObjectInputStream(new MacInputStream(s.getInputStream(),mac));
             String test;
             try {
                   while (true) {
                        test = (String)cis.readObject();
                        System.out.println(ct + " : " + test);
              } catch (EOFException e) {
                   System.out.println("["+ct + "]");
              } finally {
              if (cis!=null) cis.close();
              if (oos!=null) oos.close();
         } catch (Exception e) {
             e.printStackTrace();
        }It's exactly in the line: ObjectInputStream cis = new ObjectInputStream(new MacInputStream(s.getInputStream(),mac));Any ideas?
    I'm starting to desperate :P

    (a) I still don't see where you are writing the MAC that you're reading. You're reading something, but it's all or part of the Object stream header I described above, which is why ObjectInputStream' constructor is throwing that exception.
    (b) You don't need to override read(byte[] b) when you extend FilterInputStream, but you do need to override read(byte[] b, int offset, int length), and you need to do it like this:
    public int read(byte[] buffer, int offset, int length) throws IOException
      int count = 0;
      do
        int c = read();
        if (c < 0)
            break;
        buffer[offset+count++] = (byte)c;
      } while (count < length && available() > 0);
      return count > 0 ? count : -1;
    }This way the read() method gets to see every byte that's read and to do its MAC thing or whatever it does. The above is one of only two correct uses of available() in existence: it ensures that you only block once while reading, which is the correct behaviour e.g. on a network.

  • Java.io.StreamCorruptedException: invalid stream header

    I am having a problem with sending two objects (over a socket). I have read in other posts that this could be due to trying to receive incompatible data types but my applications work fine if I send my objects synchronously rather than asynchronously.
    I will try my best to describe what my problem is as my code is very long.
    I have a server and a client application (2 apps). Multiple clients connect to the server and send their details (as an object) to the server. The server then amends the object (adds some more data) and sends it back to the clients. Both the SendObject and ReceiveObject class are threads and I have created a Listener (within the client) that activates when an object is received (asynchronous communication). The Listener method looks to see if the event is an instance of a particular class and casts is as appropriate (as per below).
    public void receivedObject(ReceivedObjectEvent e) {
         ReceiveObjectThread obj = (ReceiveObjectThread) e.getObject();
         if(obj.getObject() instanceof Player) {
              thePlayer = (Player) obj.getObject();
              theTable.setHandData(thePlayer.getHand());
         if(obj.getObject() instanceof GameData) {
              gameData = (GameData) obj.getObject();
              theTable.setPlayerList(gameData.getOpponents());
    }The objects that are passed between applications both implement Serializable.
    This all works fine synchronously object passing. However, if I try and spawn two sendObject threads within the server and the corresponding two receive threads within the client and wait for the Listener to activate (asynchronously) I get the following error:
    java.io.StreamCorruptedException: invalid stream header: 00057372
         at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:783)
         at java.io.ObjectInputStream.<init>(ObjectInputStream.java:280)
         at ReceiveObjectThread.run(ReceiveObjectThread.java:84)
    java.io.StreamCorruptedException: invalid stream header: ACED0006
         at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:783)
         at java.io.ObjectInputStream.<init>(ObjectInputStream.java:280)
         at ReceiveObjectThread.run(ReceiveObjectThread.java:84)
    I am sure that this problem is due to my limited knowledge on socket and data transfer. Therefore any help on this one will be gratefully received.

    Hello ejp, your reply is very much appreciated.
    If I explain how I have implemented my sockets you may be able to see where I wrong.
    When a player connects, the client sends the server a �player� object. The server receives the �player� object and passes the socket from which it connected (within the server) to a socket property within the �player� class. Whenever the server needs to send an object to that client (player), it sends the output stream from the socket property within that �player� object. ( player.getSocket().getOutputStream() ).
    Below is the code from the �SendObjectThread� class.
    * This class allows an object to be passed over a Socket
    * @author Harold Clements
    * @version 1.0.1 12-Jun-2007 (12-Jul-2007)
    //http://www.seasite.niu.edu/cs580java/Object_Serialization.html
    public class SendObjectThread extends Thread {
         private OutputStream out;
         private Object obj;
          * This constructor allows the user to passes the two parameters for transmitting.
          * @param out The data stream that the object is going to be sent to.
          * @param obj The object to be sent.
         public SendObjectThread(OutputStream out, Object obj) {
              this.out = out;
              this.obj = obj;
          * The main thread
         public void run() {
              try {
                   ObjectOutputStream objOut = new ObjectOutputStream(out);
                   objOut.writeObject(obj);
                   objOut.flush();
              } catch (IOException e) {
                   e.printStackTrace();
    }The client only has one socket which is defined when the client first makes a connection with the server. The �getOutputStream()� and �getInputStream()� are used for all communication from the client.
    Is this what you described in your first option?
    The funny thing about it all is if I create a new �receiveObjectTread� and wait for that to finish, then create another �receiveObjectTread� both objects in question (Player and GameData) are received correctly and the application works. I only have the problem when I set both threads off and leave it for the �ReceivedObjectEvent� listener to pick them up and cast them (as per my first post).
    Thanks again for your help,
    Harold Clements

  • Java.util.zip.ZipException: invalid END header

    I get this error when I run the code:
    try {
    jFile = new JarFile(jarBuildFile.getAbsolutePath());
    } catch (IOException ex) {
    System.out.println("Got exception: "+ex);
    but only on very large jar files - about 2.5GB in size.
    With JDK 1.4, I get the error, jar file too large.
    With JDK 1.5, I get the above error (invalid END header).
    With JDK 1.6, it reads the file for about 5 seconds, then reports that the file cannot be opened.
    Smaller jar files work fine. This jar file has two files in it, a small XML file and a large video file.
    I'm running under windows XP.
    Doing a jar -tvf (jdk 1.5) on the large jar file works fine.
    The file was built with the jar command (jdk 1.5).
    Is this a bug in the JDK?
    Thank you!
    -Joe
    http://www.lovehorsepower.com

    Sp0ttedD0g wrote:
    I ran into this problem today too and found out it was due to the fact that I had a jar in my war that I was trying to deploy that had a file format of unicode instead of binary (it had been checked into source control system incorrectly). After updating the jar with the proper format (binary), the problem went away.The other reported problems are due to file size, not content.

  • INVALID END HEADER FORMAT error

    I have just installed the Oracle 9i database on windows NT server, but the
    Oracle Database Configuration Assistant returns INVALID END HEADER FORMAT error, eachtime i attempt to create a new database.
    Oracle 9i software is installed, but no database was created. How can i solve this problem?
    or how can i create the database manaully?
    kayode,
    [email protected]

    Hi,
    If you don't have a database error (ORA-), then you're probably hitting some sort of DBCA bug. I'd use the DBCA to generate scripts and then run the scripts manually to see if you can create a database that way.
    http://expertanswercenter.techtarget.com/eac/knowledgebaseAnswer/0,295199,sid63_gci1054696,00.html
    Are you able to create scripts through DBCA if yes then you can create your database with help of scripts.
    go through below link for manually database creation ( it is also some working in Oracle 9i. After scripts creation. Script creation is different then oracle 10g.)
    http://dbataj.blogspot.com/search/label/Database%20Creation
    if not then you hit bug ( according to above mention link) raise a iTAR.
    regards
    Taj

  • "Invalid access code (Bad parameter)" error encountered when trying to import VSS DB into TFS 2012

    I'm trying to import a VSS DB into TFS 2012 using the VSS Upgrade Wizard.
    However, I'm getting an "Invalid access code (Bad parameter)" error when I click the "List Available Projects" link button.
    I have been able to get the wizard going with a different VSS DB, but not this one.
    How can I fix this and get the import going?

    Hi,
    Thank you for your post.
    Do you use OLE Automation objects when you log on VSS? Please refer to this
    FIX: VSS OLE Automation Error Message "Bad Access Parameter"
    Regards,
    Lily Wu
    MSDN Community Support | Feedback to us
    Develop and promote your apps in Windows Store
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

  • Invalid END header format/no output available for this tool

    help me.
    I install oracle 9i into windows 2k server with pack3. when configuring the ODCA, when OUI prompt:
    invalid END header format&
    no output available for this tool.
    who can tell me that what is happen?
    before this, i had installed this version on windows 2003.

    Dear All
    I have the same problem when installing Oracle9iasR2 on a windows 2000 IBM server
    At the database configuration Assistant of the infrastructutre installation I am always getting this strange message Not a ZIP file (End Header Not found).
    We have tried a lot off scenarios to install Oracle9iasr2 but the installation always fails at the database creation with the followning message
    Not a ZIP file (End Header Not found).
    We had also tried to do the installation using a different copy of CD's with no success.
    Also the same installation on the same server was succesfull with O/S Win2003.
    Then the whole installation fails .
    If anyone has ever faced the same problem and had solved it please advice.
    Thank you in advance.
    Bill

  • Bad Signature Error When Signing With GPG

    I'm trying to sign a public PGP key but am encountering a 'Bad signature' error:
    gpg --edit-key [email protected]
    gpg> sign
    You need a passphrase to unlock the secret key for
    user: "My User <[email protected]>"
    2048-bit RSA key, ID 12345678, created 2012-01-01
    I enter my passphrase then get:
    gpg: checking created signature failed: Bad signature
    gpg: signing failed: Bad signature
    gpg: signing failed: Bad signature
    I've done some searching online but can only find old, unrelated posts or ones relating to smart cards, which I'm not using.
    The wording of the error seems to suggest that gpg is attempting to verify the signature it just created but is failing?
    I have gnupg 2.0.25-1 installed and am running the above commands via a PuTTY ssh connection.
    Any help gratefully received!

    I upgraded my Adobe to version 8 and tried the task with the same file.
    It worked without any error.

Maybe you are looking for