Can we automate importing certificate using keytool

Hi,
One of my application's requirement is to have a digital certificate at client side.
Client performs the following tasks during the deployment of the application.
1.Takes certificate from authorized CA
2. Exports digital certificate as a cer file. (CER encoded binary X.509 Certificate)
3.Use keytool (supplied with JRE) to import the certificate into keystore with an alias.
Then only my application can load the certificate from keystore.
Can we automate both step 1 and Step 2. ..?
Or atleast step 2 (because it requires the novice user to type some commands and needs little knowledge about commands as well).
Thanks in advance.

Thanks for your quick reply.
Its really useful for my requirement.
I've a small doubt.
As it said, before a keystore can be accessed, it should be loaded.
There is a method called "setCertificateEntry" for creating setting / creating certificate in Keystore
I've a certificate issed by CA and imported it to a file(.cer file) through certificate manager
How do I create Certificate from a .cer file.
Thanks in advance

Similar Messages

  • How can i automate importing certificates?

    My company is using zScaler for web filtering and we are trying to figure out how we can import certificate into firefox. I have tried copying the cert.db from one machine to another but the problem is that the page only loads with text, which implies the certificate is half working. if we remove the cert and manually import the cert it works fine. we are trying to find a way to automate the deployment of this certificate to 100+ machines. Please advise if this is possible.

    I have not done this before, however there is posted information about with how to attempt this, for example: [http://community.spiceworks.com/how_to/show/15158-firefox-trust-a-local-certificate-authority-for-all-users-and-computers]
    There is also the ESR community that does this alot. Check out their lists for community questions [https://www.mozilla.org/en-US/firefox/organizations/]

  • Cannot import certificate using keytool

    Hi,
    I used the below command to generate the key pairs and CSR:
    keytool -genkey -alias myalias -keyalg RSA -keystore .keystore
    keytool -certreq -keystore .keystore -alias myalias -file jetco.csr
    Then I copied the CSR and signed by the CA. The CA issued the certificate and I import the certificate (filename: DownloadCert) with the following command:
    (the certificate from the CA is in V3 X.509 base64 encoded)
    keytool -import -alias myalias -file DownloadCert -keypass ****** -keystore .keystore -storepass ******
    Then I got the error : keytool error: java.security.cert.CertificateException: IOException: Sequence tag error.
    Does anyone know how to fix the above problem?
    Thank you very much! It is very urgent.... PLEASE!!!!
    VL

    u might not have saved the attachment properly. if u r
    using windows, can u c the certificate clearly by
    clicking on the file. the filename must end with a
    .cer extension so that u can double click on it.After I modified the content of the file from CA. Now I can import the certificate in a keystore file.
    Thank you for your help.

  • How can I (automatically) import new photos of the photostream on my local disc (Mac)? Don't want to use new icloud service. Simply import.

    New Photo app on Mac.
    How can I (automatically) import new photos of the photo stream on my local disc (Mac)? Don't want to use new icloud service. Simply import.
    With iPhoto every new photo was automatically imported and saved on my local disk (with "full resolution" that's what I only need). In the new photo app I have still my photo stream and when I move a photo (drag and drop from the photo stream) to a new album it indicates a (plus). My understanding is that the photo is now copied to my local disk. But when I deleted the photo in the photo stream it was also deleted in the album !?
    If that is the case I can use the photo stream only until I reach the max of 1.000 photos, then I have to delete photos and I will have no copy left.
    How can I "physically" copy a photo of the photo stream to my local disk? I just want to "transfer" all pictures taken with Ipads, Iphones to my central storage on the Mac. Please don't propose to connect it via iTunes (cable) to the Mac.
    Any other suggestions?
    thx
    -Tom

    The amazing device cannot do it because no amazing developer has written an app for it.  There is some interest, others have asked, but i have a hunch that the market is fairly limited, and no developer has jumped at the chance just yet.
    Any sort of tethered approach means try to feed the material to the pad thru the cck.  Which means the app would have to use the allowed/existing cck pathway in a manner that does not violate the sandbox rules.  That may be the problem.

  • How can I automatically deploy certificates to iphones

    How can I automatically deploy certificates to iphones from an internal Windows Certificate Root Authority?  I want to use device certs with a combination of username and password in order to access a secure wireless network.
    I have this working fine with AD joined Windows PCs - I am just having trouble doing the same for our many iphones.
    Many thanks in advance

    Most corporations nowadays are moving towards responsive designs with a mobile first approach.  This tends to be the most efficient and compatible since there is no need for javascript or other scripts to redirect users.
    The following is a simple example for phones and desktops only, and most examples I was finding were that way due to their publishing date.
    http://css-tricks.com/snippets/javascript/redirect-mobile-devices/
    The trick is going to be getting lists of devices and resolutions to make sure they are all captured which can be a major pain since that information updates all the time.  With that said, if I were you doing it this way I would do away with the tablet version.

  • How to create a certificate using keytool / terminal?

    I have problems with creating certificates using the terminal. I use the instructions below and typed in all the required information. When it asks me to type "yes" and confirm, the whole process just starts from the beginning over and over and I have to type in the same things. What do I do wrong? How do I confirm the information I typed in?
    I am trying to create a certificate to sign apps for GooglePlay and Amazon. I am using DPS Professional.
    Thanks for help!
    Instructions:
    (Mac OS) Create a certificate file using Keytool
    Open Terminal, which is located in the Applications > Utilities folder.
    Type (or paste) the following line (replace “myname.key.p12” with the actual name of your certificate):
    1
    keytool -genkey -v -keystore myname.key.p12 -alias alias_name -keyalg RSA -keysize 2048 -storetype pkcs12 -validity 10000
    Specifying “10000” sets the expiration date after 22 October 2033.
    Enter and reenter a password. Until the Viewer Builder supports the creation of custom Android apps, it's necessary to share this password with Adobe. Create a password that you can share.
    Follow the prompts to specify the certificate information.
    When prompted to confirm choices, enter yes, and then press Return to use the same password.
    A certificate is created in your prompt location, such as your user name folder. Copy this certificate file to a known location. Write down the password as well.

    It could be access/rights issue. Enable root user and try again.

  • How can I automatically import my emails from AOL?

    Until I changed my AOL password last week (it got hacked) all of my email from AOL was automatically transferred to my Gmail account. My son set this up for me but he is overseas now in the military. How can I get Gmail to automatically "import" or harvest my AOL mail as it was doing until I had to change the AOL password?
    Thanks!
    John Lentz
    [email protected]

    Have you set up your iCloud email account (under Settings > Mail, Contacts, Calendars)?
    If so, have you turned on "Mail" under Settings > iCloud?
    Are you certain your Apple ID on your iPad is identical to the one used for your iCloud account elsewhere?

  • (newbie) Importing certificate with keytool..?

    I'm trying to import a certificate with:
    * keytool -import -alias mycert -file lalakis.pem
    but I keep getting:
    ~ keytool error: java.lang.Exception: Input not an X.509 certificate
    It is:
    - An OpenSSL generated certificate with
    - Signature Algorithm: PKCS #1 MD5 With RSA Encryption and
    - Subject PK Algorithm: PKCS #1 RSA Encryption
    Should I use some other options..?

    Normally OpenSSL certificate includes extra human readable information. Please remove all characters before -----BEGIN CERTIFICATE---- and after ----END CERTIFICATE----- (including blank lines), and try again.

  • How can we automate compass rotation using UIAutomation

    Hello,
    I have to automate compass application using Instruments. How can this be possible?

    Hi
    I agree with the others!
    Here you have a simple brute-force example.
    Greetings
    juergen
    =s=i=g=n=a=t=u=r=e= Click on the Star and see what happens :-) =s=i=g=n=a=t=u=r=e=
    Attachments:
    Add.zip ‏138 KB

  • Can I automate import, then sample rate conversion, then mp3 export ?

    I do radio spots, lots of them, and every day I have to take my spot that is a 48k wav, convert it to 44.1k, then convert it to a mp3, them distribute via email.
    Can I automate this task?

    Rather than trying to automate iTunes, it might be easier to do the conversion in one go with a utility such as Sound Converter or Switch.
    Hope this helps.

  • Can we automate anu player using java?

    i want to automate audio player.please suggest me

    I am trying to access .net components (written in C#) from JAVA and is studing the possibility using NJAWIN.
    Since NJAWIN is for COM, first I made my .net component exposed to COM (this is another story) and build it.
    I am able to use jcomgen.exe to generate stubs against the tlb file built from the .net project. And my simple test seems successful.
    My questions are:
    1. Is there other way (opensource or freeware) I can access .net component from java directly without going through COM?
    2. The component only consists regular classes and methods which mainly doing the database access and data management. There is no controls ot events (no gui). Can I still use NJAWIN (after exposing it to COM) and rely on it?
    Thanks for the help.

  • How can I automatically import images into iBook Author?

    I'd like to make a photo book with a couple hundred photos.
    Aside from manually inserting each page, inserting each image, placing/resizing it on the page, is there an easier way to insert many images, and flow them one per page?
    thanks in advance

    There is no built-in support for automatic inserts, sorry.
    I can imagine whipping up an Autormator/AppleScript to do that job, however - in which case success lies in your abilities to put that together, of course.

  • How I can Export and Import tables using BRTOOL ?

    Dear All,
    Since we upgrade the oracle from 9.0.2 to 10.2.2 we not using SAPDBA any more.
    please help me if you now how to export and import tables in sapr3 using brtools?
    thanks and Best regards,
    Chrisna

    Dear Chrisna,
    first of all you should get the recent version of the BRTOOLS (currently it's BRTOOLS 7.00 (<b>26</b>)). The developers are working hard on making these tools more reliable and usable so you should not deny the improvements to yourself.
    Now to your problem:
    Try this call:
    brspace -f tbexport -o SAPR3 -t SSF_PSE_D,SSF_PSE_H,HTTPURLLOC
    You don't need to specify a tablespace; it's just a additional option to select what tables you like to export.
    You may also want to check these notes for further "enlightment"
    <a href="http://service.sap.com/sap/support/notes/976435">#976435     Support for Oracle Data Pump in BRSPACE</a>
    <a href="http://service.sap.com/sap/support/notes/713497">#713497 - New BRSPACE options for "Reorg", "Rebuild" and "Tablespace"</a>
    <a href="http://service.sap.com/sap/support/notes/647697">#647697 - BRSPACE - New tool for Oracle database administration</a>
    <a href="http://service.sap.com/sap/support/notes/646681">#646681 - Reorganizing tables with BRSPACE</a>
    <a href="http://service.sap.com/sap/support/notes/12741">#12741 - Current versions of BR*Tools and SAPDBA</a>
    <a href="http://service.sap.com/sap/support/notes/651812">#651812 - FAQ: BR*TOOLS and SAPDBA</a>
    KR Lars

  • Can I automatically import multiple iCal appointments with addresses to Apple Maps?

    I am planning an itinerary and I have all of the addresses for museums and restaurants in iCal. I would now like to see all of these locations on Apple Maps. Is it possible to import them all?

    I relaced an older AEBS with the new one, recently, and did not need to import anything, but if you can save the configuration file from your old one, then you can import it to the new one. I've never tried that when I switched, and it didn't seem to matter which suggests the configuration file may be on disk somewhere.

  • Using keytool to generate self signed cert. for Microsft Certificate Mrg.

    Hi All,
    I want to be able to generate a self signed certificate that I can Import into
    Microsoft's Certificate Manager, to enable an HTTPS Listener for
    Microsoft's WinRM and WinRS.
    The certificate would only be for internal use, not used externally.
    Here's the problem. I can create a certificate using this (path obscured):
    "C:\Program Files\.....\jre\bin\keytool" -genkey -al
    ias dMobX -keyalg RSA -keysize 1024 -sigalg SHA1withRSA -dname "CN=your-f5c57803
    53" -keypass changeit -validity 90 -storetype pkcs12 -keystore "C:\Program Files
    \......\jre\lib\keystore\.keystore" -storepass changeit
    "C:\Program Files\......\jre\bin\keytool" -export -alias dMob
    X -file "C:\Program Files\......\jre\lib\keystore\dMobX.cer" -stor
    etype pkcs12 -keystore "C:\Program Files\.......\jre\lib\keystore\.
    keystore" -storepass changeit -v
    Microsoft's Certificate Manager will accept it, the .cer, using "Import", into
    Trusted Root Certification Authorities, but when I run the command to create the HTTPS Listener, I get this error message:
    The WS-Management service cannot find the certificate that was requested.
    If I use another tool, like selfssl, I can generate a self signed certificate using:
    selfssl /N:CN=your-f5c5780353 /K:1024 /V:90 /P:443 /T
    This will populate a certificate in Trusted Root Certification Authorities,
    and when I run the command to create the HTTPS Listener, it succeeds with
    no problem.
    So my question is, am I doing something wrong with keytool, or are there
    extra steps that I need to take, or is it even capable of generating a "self signed
    certificate" that will work in the above case?
    There are some concepts involved, certificate wise, that I'm not sure about.
    Do I need to create a CSR and use a tool like openssl, as a CA, and
    use the resulting certificate?
    I just want to be able to programmatically create the needed certificate using keytool, or
    using an API.
    Thanks,

    Download the latest JDK on http://download.java.net/jdk7/binaries/.
    Run "keytool -genkeypair -ext KU=? -ext EKU=? ...". Substitute the "?" with the usages you see in the other cert (for example, "digitalSignature" or "codeSigning". If there are multiple ones, separate with comma).

Maybe you are looking for

  • SSO Application Configuration .msc - Unable to load mmc and unable to uninstall/repair

    This tool was installed on a QA server by an ex-employee and nobody knows for sure if it ever worked.  Attempting to uninstall/repair fails with below errors in the event log. The description for Event ID 11001 from source MsiInstaller cannot be foun

  • How to making login id as one field in the coding

    hi, I need to make the id(login in sap) as one of the field and that should be automatically assigned to it once we login . wht kind of modifications to be done for this.....pls help me... Saurabh.

  • Poster Frames on Ripped Videos Lost, Not Synced to iPad or iPhone

    iTunes 10.2.1 on latest Mac OS X 10.6.7. I have videos which I've ripped from Blu-ray via MakeMKV and Handbrake. When I import them into iTunes and then set a poster frame, more often than not: 1. The poster frame is easily lost, especially if I do a

  • Pricing Totals not appearing in B2C web shop

    Hello All, We are using list prices in product catalog and in B2C  web shop. We are unable to see the pricing totals in the save order screen.The pricing totals and prices are appearing in in the back end(SAP GUI). Could any one suggest where do we h

  • Another person asking about moving files in lightroom

    I have spent several hours today trying to sort out, what I thought was going to be an easy question.  Moving files from my internal hdd to an external one. Ok, I know it should be easy, a trillion posts say how to do this. Sys info (from LR itself):