Cheap Domains, $1 .COM Websites! - Free .COM (or $1.99) on Many Products!
 
Only Minimal Purchase Req'd on Many Free/$1.99 .COM Offers.    And Our Sale Domains are Often Under $2 or $3/year with No Further Purchase Req'd.
 
Plus, almost ALWAYS 15% OFF Everything Not Already Discounted.    15% OFF Most Renewals too!      New: Business-Growth Website-Builders and Hosting!
 

 *ICANN fee adds 18¢ many domains; tas applies some areas.  Our $1 Website Builder with Free .COM is based on 12 months at $1/mo.   Multipile or "Stacked" discounts in same purchase often disallowed (may require separate transactions).  Click for details.

 
Cheap Domains Cheap Domain Names

  
Use Promo HDX for at least
Cheap .com
that's not already On Sale!*
 

Cheap Domains     $1 Websites     Free USA-based Sales/Support:  (800) 655-5512
 

.COM $7.64 (Promo: HDX) |  .NET $10.19  |  .SITE $2.99  |  .ORG $9.99  |  .INFO $4.99  |  .UK $7.64  |  .EU $6.79

Cheap Domains include FREE:  100 Email Addresses & Account, Full DNS Control, Domain Forwarding, Masking, Registrant-Change/Transfer, Monitoring/Alerts, Locking, Expiration Protection, More!

Cheap Domains - Find Yours Now:    
 
Most prices shown
use Promo Code: HDX.  This search function, and most product pages, display higher prices at first, but don't worry,  Discounts appear in Shopping Cart when Promo Code Entered    details

Free .COM Domains!   ...with many products...  

 $1 Website Instantly     Business Website Builder

 Most cPanel & Plesk Hosting    Some WordPress Packages

$1.99 .COM Domains   ...on much else, often including:

Many Email, Calendar, Storage Plans Powerful SSL Certificates, more!

 
Terms & Conditions Here.  Add a .COM to Cart to verify price if product description not specific.

 

 
 

 Cheap Website       Cheap WordPress Hosting        Cheap Website Builder - Easy, Instant!    
Cheap Dedicated Servers       Cheap Virtual Private Servers      
Blogcast and Podcast 

 
Cheap Domains | Availability Check:
 
  

Frequently Asked Questions

Help Center Search

Sign Java Code

Print this Article
$1 Domains
Last Updated: September 31, 2017 2:33 PM

Several tools are required to package and sign Java code, including keytool, jar and jarsigner. Beginning with JDK 5.0, jarsigner can generate signatures that include a time stamp, allowing validation that the JAR file was signed while the code signing certificate was still valid.

Approach 1 – Request a New Code Signing Certificate

  1. Download the JDK, if necessary
  2. Request a Code Signing Certificate from Starfield Technologies.
    • Create a new key store. A key store is a place where secure certificates are stored. This example will create a custom key store named "codesignstore" to be used only for a code signing certificate and the associated private key.
      keytool -genkey -alias codesigncert -keypass <yourkeypwd> -keyalg RSA -keysize 2048 -dname "CN=displayname,O=companyname,C=US,ST=state,L=city" -keystore codesignstore -storepass <yourstorepwd>
    • Create a Certificate Signing Request (CSR). A private key will be created and stored in the key store named "codesignstore". A CSR file named "mycsr.pem" will be created in the current working directory.
      keytool -certreq -v -alias codesigncert -file mycsr.pem -keystore codesignstore
    • Purchase a code signing certificate.
    • Click on the purchased code signing certificate credit in “My Account”. This will take you to the GoDaddy/Starfield Secure Certificate Services Account Management web application.The CSR generation method must be set to manual on the request form for the CSR field to be visible.
    • Submit CSR as part of the code signing request.
      • After opening the file “mycsr.pem” in an editor, copy and paste the entire content of the file (including the lines containing “BEGIN NEW CERTIFICATE REQUEST” and “END NEW CERTIFICATE REQUEST”) into the appropriate section of the code signing request form.
    • The company information you have supplied will be verified. The Registration Authority (RA) may contact you to provide additional information, if required.
    • Once the code signing certificate has been issued, you will receive an email message with a link to download the certificate file and any associated intermediate certificates.
  3. Install the code signing certificate, in the same key store created earlier. The following example expects the code signing certificate file to be named “mycert.spc”. The certificate file is expected to be in the current working folder and in PKCS#7 format.
    keytool -import -keystore codesignstore -storepass <yourstorepwd> -alias codesigncert -file mycert.spc
  4. Create a JAR file from Java class files, using the jar tool
    jar cvf myapp.jar myapp.class
  5. Sign the JAR file using jarsigner, using the code signing certificate and the private key
    jarsigner -verbose -keystore codesignstore -storepass <yourstorepwd> -keypass <yourkeypwd> myapp.jar codesigncert
    • ‘codesignstore’ is an alias to the key store where the code signing cert, the private key and all other certificates in the chain are contained.
    • The unsigned input file name is “myapp.jar” and will be overwritten with the signed version of the file. Use the “-signedjar” command line option to specify separate input and output file names.
    • ‘codesigncert’ is an alias to the private key in the key store.
    The following example adds time stamping options to the same example presented above.
    jarsigner -verbose -keystore codesignstore -storepass <yourstorepwd> -keypass <yourkeypwd> -tsa http://tsa.starfieldtech.com/ myapp.jar codesigncert
  6. Verify the signed JAR file
    jarsigner -verify -verbose -certs myapp.jar
  7. Distribute the code

Approach 2 – Use Existing PKCS#12 File, Containing Both Code Signing Certificate and Private Key

  1. Download the JDK, if necessary
  2. Verify that the PFX/P12 file can be used with jarsigner. Execute the following command, the alias name required in step 5 will be displayed near the top of the output:
    keytool -list -storetype pkcs12 -keystore mycert.pfx -v
  3. Create a JAR file from Java class files, using the jar tool:
    jar cvf myapp.jar myapp.class
  4. Sign the JAR file using jarsigner, using the code signing certificate and the private key:
    jarsigner -storetype pkcs12 -keystore mycert.pfx myapp.jar "aliasname"
    • "mycert.pfx" is the full path to the PFX/P12 file containing the code signing certificate and the private key. The file should also include all intermediate certificates.
    • "aliasname" is displayed in the output of step 2, near the top. If the PFX/P12 file was exported from Windows, the alias name will effectively be a GUID.
    • When prompted, enter the password associated with the private key in the PFX/P12 file. You may also include the "-storepass" option to specifiy the password on the command line.
    • The unsigned input file name is "myapp.jar" and will be overwritten with the signed version of the file. Use the "-signedjar" command line option to specify separate input and output file names.
    The following example adds time stamping options to the same example presented above:
    jarsigner -storetype pkcs12 -keystore mycert.pfx -tsa http://tsa.starfieldtech.com/ myapp.jar "aliasname"
  5. Verify the signed JAR file
    jarsigner -verify -verbose -certs myapp.jar
  6. Distribute the code

Links

Cheap Domain Names
 


Toll Free Technical Support from a USA Call Center, 24 hours a day, 365 days a year:    (800) 655-5512
 
Call us with any sales or support question.     Place Orders by Phone.    Our USA-based Help Desk speaks your language.
 

Call Centers located in the Greater Phoenix metro area and Central Iowa, USA.     Technical Support also available in Spanish   New to Us?  Get a free account in 60 seconds.


 

 

 $1 Cheap Domains   |   $1 Websites   |   Product Catalog   |   Sale Price FAQ   |   Help Pages   |   FAQ   |   Free Phone Support   |   Free WHOIS Lookup   |   My Cart   |   Login

 
ICANN fee of 18 cents [$0.18] may apply on some domain names.    Notice for .eu and some other registering inbound
domain transfers: WHOIS may show domain held under registry
Weiled Weast Domains and/or HostingDude.com.   Legal Agreements.

(https://legacy.hostingdude.com)
 

 


 

Copyright © 2003 - 2019  HostingDude, Inc.  All Rights Reserved.  No reprint or re-use without written authorization.