java.lang.Object
java.util.zip.ZipEntry
java.util.jar.JarEntry
- All Implemented Interfaces:
- Cloneable
- See Also:
- Top Examples, Source Code
public static final int CENATT
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static final int CENATX
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static final int CENCOM
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static final int CENCRC
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static final int CENDSK
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static final int CENEXT
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static final int CENFLG
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static final int CENHDR
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static final int CENHOW
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static final int CENLEN
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static final int CENNAM
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static final int CENOFF
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static final long CENSIG
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static final int CENSIZ
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static final int CENTIM
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static final int CENVEM
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static final int CENVER
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static final int ENDCOM
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static final int ENDHDR
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static final int ENDOFF
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static final long ENDSIG
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static final int ENDSIZ
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static final int ENDSUB
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static final int ENDTOT
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static final int EXTCRC
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static final int EXTHDR
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static final int EXTLEN
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static final long EXTSIG
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static final int EXTSIZ
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public Attributes getAttributes()
throws IOException
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public Certificate[] getCertificates()
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
[1568]Verifying signed jars
By Anonymous on 2005/10/08 18:18:45 Rate
//Verifying signed jars
private Certificate [ ] getCertificates ( JarEntry entry )
{
try
{
Certificate certificates [ ] = entry.getCertificates ( ) ;
if ( certificates != null )
return certificates;
// CodeSigner [ ] codeSigners = entry.getCodeSigners ( ) ;
Method getCodeSigners = entry.getClass ( ) .getMethod (
"getCodeSigners", new Class [ 0 ] ) ;
Object [ ] codeSigners = ( Object [ ] ) getCodeSigners.invoke ( entry,
new Object [ 0 ] ) ;
if ( codeSigners != null && codeSigners.length > 0 )
{
// List list = ( CodeSigner ) codeSigners [ 0 ] ) .getSignerCertPath ( ) .
getCertificates ( ) ;
Class codeSigner = Class.forName ( "java.security.CodeSigner" ) ;
Method getSignerCertPath = codeSigner.getMethod (
"getSignerCertPath", new Class [ 0 ] ) ;
CertPath certPath = ( CertPath ) getSignerCertPath.invoke (
Array.get ( codeSigners, 0 ) , new Object [ 0 ] ) ;
List list = certPath.getCertificates ( ) ;
return ( Certificate [ ] ) list.toArray ( new
Certificate [ list.size ( ) ] ) ;
}
}
catch ( NoSuchMethodException e )
{
// fail quietly if called by Java 1.4 runtime
}
catch ( Exception e )
{
logger.error ( "Error collecting jar entry certificate", e ) ;
}
return null;
public CodeSigner[] getCodeSigners()
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public JarEntry(String name)
- See Also:
- IllegalArgumentException, NullPointerException
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public JarEntry(JarEntry je)
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public JarEntry(ZipEntry ze)
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static final int LOCCRC
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static final int LOCEXT
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static final int LOCFLG
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static final int LOCHDR
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static final int LOCHOW
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static final int LOCLEN
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static final int LOCNAM
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static final long LOCSIG
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static final int LOCSIZ
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static final int LOCTIM
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples
public static final int LOCVER
- Geek's Notes:
- Description Add your codes or notes Search More Java Examples