Public keys on the Modules of Code

Greetings,

I would like to know how to extract the public key modules are already installed on the BlackBerry.

I know there is the CodeSignigKey.getPublicKey () method, which is what I guess you would be able to extract the public key.  I do the following:

...
int handle = CodeModuleManager.getModuleHandle("Argle");
byte[] pubKey = CodeSigningKey.get(handle,CodeSigningKey.RRT_SIGNER_ID).getPublicKey();
...

My assumptions are that each single program (considering third-party applications) should have a signature RRT.  It's what you do when you sign your apps (three signatures RRT, RBB, CPR).

What I don't understand is this:

Is CodeSigningKey.RRT_SIGNER_ID id signatory for the pair of keys to the RIM and so that's the reason why I always get a key public zero for third-party applications?

Are the public key embedded in the modules or can they be extracted of the modules?

Thank you

Sheran

Okay, I was incorrectly assuming that the CodeSigningKey would allow me to extract the public key from the developer who signed the module.  Thank you for that clarification.

Tags: BlackBerry Developers

Similar Questions

  • License key for the module?

    Cannot find the license key for the Onedrive to download the Photo module anymore. How can I get that again?

    Please write to us at [email protected] attaching your order number and we will send you your license key.

  • Oracle FTP adapter - possibility of using the public key and the password

    Hi all

    One needs to connect to a target SFTP server using the public key and password using the Oracle's FTP adapter. Is it possible and feasible?

    I think it's usually one of them that would be used (the password or public key).

    Could someone help me with this please?

    Thank you

    Kind regards

    Nanan

    Hi all

    We checked it with Oracle and it happens that this feature is not available in the product. It is probably considered to be an improvement.

    Hope that this update would be useful at all.

    Thank you

    Kind regards

    Nanan

  • Generate public and private keys within the smart card

    Hi all

    I use this code to generate public and private keys within the smart card.

    KeyPair kp = new pair of keys (KeyPair.ALG_RSA_CRT, KeyBuilder.LENGTH_RSA_512);
    kp.genKeyPair ();
    PrivateKey prikey = kp.getPrivate ();
    PublicKey pubkey = kp.getPublic ();

    This code runs without error.

    I need to obtain the public key of the smart card. So I need to get the public key to a byte array.
    But I can't get these keys in array of bytes of plain text.

    The methods I can get for pubkey object are

    pubkey.clearKey ();
    pubkey. Equals (obj);
    pubkey.getSize ();
    pubkey.getType ();
    pubkey.isInitialized (); only these.

    I use
    Eclipse Version: 3.4.1 (level of agreement of the compiler = 1.4)
    Jcop plugin (to connect with the real map and to test the java code in virtual card provided by JCOP)
    OmniKey5321 (characters without contact) card reader

    What is the reason to get those above methods pubkey object? Is it a version problem?
    How can I get the public key in ordinary byte array? Is this possible?
    If it is not possible, is there a way to get the public key as a certificate of export or something another solution?

    If my script is not a possible strategy, how can I use private public keys to send the applet-specific data? Is there a better way to do it?

    Published by: 863766 on June 6, 2011 12:16 AM
    RSAPublicKey pubkey = kp.getPublic();
    

    then

    pubkey.getExponent(...); pubkey.getModulus(...);
    
  • How to get the public key using modulus and exponent

    Dear Sir
    I modulo and exp of the public key, how can I combine the GE the full public key, in the host application. These values are coming from the java card?
    I get these as follows:
                      rAPDU = channel.transmit(new CommandAPDU(getPublicKeyModCommand));
                      if (rAPDU.getSW() != 0x9000)
                      {  
                           System.out.println("Could not get the modulus");
                      }
                      if (rAPDU.getSW() == 0x9000)
                      {  
                           modulus = new BigInteger(rAPDU.getData());
                           arrayPrint(rAPDU.getData());
                      } 
                      
                      rAPDU = channel.transmit(new CommandAPDU(getPublicKeyExpCommand));
                      if (rAPDU.getSW() != 0x9000)
                      {  
                           System.out.println("Could not get exp");
                      }
                      System.out.println();
                      if (rAPDU.getSW() == 0x9000)
                      {
                           exponent = new BigInteger(rAPDU.getData());
                           arrayPrint(rAPDU.getData());
                      } 

    EJP wrote:

    In fact, I was using a deprecated function where the problem arose.

    N ° with the help of an obsolete method does not cause this problem. In fact:

    The stack trace is from this line:

    X509Certificate userCert = createClientCert( user_PublicKey, CA_PrivateKey, CA_PublicKey );
    

    The code for this method has not been demonstrated, so he's probably trying to use BC. The factory key code must have worked very well to get to this day.

    See you soon,.
    Shane

  • How to get the public key of a .crt file

    Hello

    I'm new to cryptography, please correct me if I understand well about the digital signature and I need help to get the public key.
    I have a x.crt file that contains the following fields
    (1) x
    (2)
    (3) certificate of

    This certificate contains the following fields
    version of certificate
    owner ID
    name
    public key
    signature (which is obtained by the signature of the beginning of the x.crt public key with the private key)
    now, I need to check if the signature for this I need to get the public key and the signature of the .crt file. Is - this way I need to check the certificate? Please help me because I am a newbie in Cryptography

    You have to look at the Javadoc for BigInteger-

    BigInteger modulus = new BigInteger(1, dataPub);
    

    This will not solve the problem of the module being negative, but I don't think it will solve your problem.

  • Rsync for lenovo ix2 with ssh public key

    Dear Lenovo,

    Bought your ix2.

    And I would like to use as a backup device on another place.

    So I have a linux sever rsyncing to the ix2.

    Cron in order to synchronize the files I need, I want to add the public key in the authorized keys file.

    However, this doesn't seem to be possible.

    When you enable the rsync rsync user Protocol, but he has a home directory: / pools/A/A0

    to which he has no right to write a file of authorized keys.

    This is NOT very practical.

    Try to synchronize the other way around, through a copy on the ix2 job, is also not an option, because it will then try to copy the entire tree, without being able to clarify what I need to copy

    It would be possible to

    (1) add a home directory for the user rsync in which to store the file authorized_keys

    (2) add the Taks copy module options, to specify what to copy? for example *.db / only the content of the directory, no subdirectories?

    (3) give me another solution to this challenge?

    Stephan

    Do you have a restart of the ix2.

    This reveals another challenge: at each reboot the rsync home dir is deleted

    However, as a result of new steps 1-4

    then enter the key:

    SSH-copy-id - i /root/.ssh/id_rsa.pub rsync@nasip

    Now it works!

  • Repeatable encryption with RSA public key encryption

    Hello

    I have the following problem: I try to encrypt a byte array with an RSA public key encryption and want to get the same byte array encrypted for every call to doFinal().

    Object*.
    Two people (a and b) may share the same secret. Yet they don't trust each other until what they have confirmed that they share the same secret. To check if both share the same secret the following protocol apply (via a communication channel not secure assistance from person c they don't trust either). Also, there is no one which may help to establish trust (i.e. building confidence channels).

    (1) generates the public key / private RSA
    (2) a figure his secret with the RSA public key
    (3) one sends the secret encrypted with its public RSA key for b
    (4) b uses the RSA a public key to encrypt his secret
    (5) in the case of the encrypted secret of a matches the secret encrypted b, then make (6), if a and b do not share the same secret, as they are in conversatzion
    (6) b generates his own public key / private RSA
    (7) b figure (not encrypted) secret with its private key
    (8) b figure his secret (encrypted with its private key), as well as his public key with the public key of a
    (9) b sends his secret (encrypted with its private key) and its public key in a
    (10) one decrypts the secret and b public key with its private key
    (11) one decrypts the secret with the public key of b
    (12) checks if the secret received b acually meets that one knows = > trust established, finishing


    So, I want to achieve is that the following code prints "true":
    byte[] potentialSecret = new byte[]{1, 2, 3, 4, 5};
    KeyPairGenerator kpg = KeyPairGenerator.getInstance(RSA);
    kpg.initialize(512);
    KeyPair kp = kpg.generateKeyPair();
    PublicKey key = kp.getPublic();
    Cipher c = Cipher.getInstance(RSA);
    c.init(Cipher.ENCRYPT_MODE, key);
    System.out.println(Arrays.equals(c.doFinal(xy), c.doFinal(xy)));
    I tried to 'tinker' with initialization vectors, but still finished with the exceptions of various type.


    Thank you very much
    Bjoern


    How can PS: btw, I markup code? It is my first assignment in the Oracle forums.

    If your security is based on a secret that can be 8bits then you only 8bits of security. An attacker could send a request with their own key pair with all the data. The other party would return the text key and the encryption algorithm and then after less than 256 RSA cryptographic operations you have the secret (if it's 1 byte). You can then send the request with the correct secret.

    See you soon,.
    Shane

  • [SOLVED] How to create public keys to ssh to ESXi to another host?

    I have read a number of different sites trying to find information on how to do it properly, but I had no luck.  I'm afraid at this point I'm all mixed up or miss me something simple [painfully].

    My goal is to create keys so that I can ssh/scp, as root, the ESXi server to another server in linux/unix under a different name.  Most, if not all of the sites I found coverage today the reverse: ssh/scp from another machine to the ESXi server.  I assume that ssh ESXi-> another host via keys is possible...?

    I believe that I'm almost there, but in all honesty, I don't know.  Here's what I've done so far.

    • RSA and DSA keys with dropbear created on the ESXi Server
    • convert keys RSA and DSA dropbear ssh format
    • Cat's public RSA and DSA keys in the ~/.ssh/authorized_keys on the server that I would like to ssh/scp
      • even tried to make a copy of authorized_keys as authorized_keys2 on the destination server
      • same CAT had the public keys of the ESXi authorized_keys & authorized_keys2
    • went up to copy the private key (!) from the ESXi server on the server I ssh/scp area in

    In regards to the box, I'm remote in I

    • keys generated with ssh-keygen - t dsa and rsa
    • typed in a sentence
    • CAT had the public key in .ssh/authorized_keys on ESXi box
      • as above in desperation I added it in the file authorized_keys local
      • copied authorized_keys to authorized_keys2
    • copied private keys (!) of the destination inbox ESXi machine

    I tried ssh username FQDN, ssh username@FQDN-l and with the IP address itself, whenever I was asked for a password.  Naturally if I just ssh hostname it trying to connect as root, which is not allowed and will fail.  Again, I apologize because I'm probably all mixed now. might be wise to simply erase all keys & start over.

    Is this possible?

    Is anyone interested in lending a hand?

    Resources

    http://communities.VMware.com/message/1373428#1373428

    http://communities.VMware.com/docs/doc-8890

    http://pkeck.myWeb.uga.edu/SSH/

    http://computerpr0n.com/2011/04/ESXi-remote-management-part-2/

    http://oreilly.com/pub/h/66

    I blogged about this recently:

    http://blog.Cowger.us/?p=15

  • public key error trying to import customization specifications

    Hello, I am trying to export sheet customization of my vCenter 4.0 installation and import them into my vCenter 4.1.  When I try to import it to vCenter 4.1, I get this error "Cannot decrypt the password":

    «The public key in the specification, does not match the public key of vCenter.»  Click OK to open the Customization Wizard of specification, retype the password and continue with the import. »

    I can enter the password again and continue the import with no problems, but I don't own any customization specifications and don't know any of the passwords.

    Us would appreciate it if anyone can help please correct me any problem I have with this key public vCenter?

    Thanks in advance!

    Shayne

    sh4yne wrote:

    I can enter the password again and continue the import with no problems, but I don't own any customization specifications and don't know any of the passwords.

    find someone who does, or create new customization techniques.  Because the passwords are encrypted in the customization specification, when you export an environment and in another, you must update the administrator password.

  • A fatal error occurred when attempting to access the SSL server credential private key. The error code returned from the cryptographic module is 0x8009030D. The internal error state is 10001.

    Hello

    I just bought an HP computer, Windows 8 Pro, x64bit. I worked OK for a week and then started to freeze. It freezes all the time. I'll send the error message in the event log. I'd appreciate your help because I've had enough of this gel and I turn it works all the time.

    Log name: System
    Source: Schannel
    Date: 12/07/2013-12:55:12
    Event ID: 36870
    Task category: no
    Level: error
    Keywords:
    User: SYSTEM
    Computer: Aleksey
    Description:
    A fatal error occurred when attempting to access the SSL server credential private key. The error code returned from the cryptographic module is 0x8009030D. The internal error state is 10001.
    The event XML:
    http://schemas.Microsoft.com/win/2004/08/events/event">
     
       
        36870
        0
        2
        0
        0
        0 x 8000000000000000
       
        7179
       
       
        System
        Aleksey
       
     

     
        Server
        0x8009030d
        10001
     

    Thank you

    Hi Aleksey,

    I appreciate the efforts that you put to publish the query on this forum.

    Please help me with the following information about this issue:

    (1) is the computer that is connected to a domain network?

    (2) when exactly you receive the error message? It is by accessing any application?

    If the computer is connected to a domain network, I suggest you send the request on 8 Windows IT Pro. Check out the link:

    http://social.technet.Microsoft.com/forums/Windows/en-us/home?category=w8itpro

    Please let us know if the computer is not in a domain. We will be happy to help you come.

  • When you try to join my key, the option "Attach my public key" is deleted so I can't use it.

    This is a reference to the "Digital Signature and encryption of Messages. When you try to send my key by e-mail, the option "Attach my public key" is deleted so I can't use it. I have a work around, but it's a little embarrassing.

    Any ideas?

    Thank you very much

    Kevin

    When your issue has been resolved can mark this thread as "solved" Please?
    Thank you.

  • How to put the name of the Module file and use the current file name in the code?

    Hello

    I create SequenceCall (in MainSequence), but there must be the Module file name and existing file where the module. I found an old function that are not part of the API (TS_SequenceCallModuleSetUseCurrentFile() and TS_SequenceCallModuleSetSequenceName(). Those who are in the help file, but not in tsapicvi.c.

    You can help someone with this (CVI code)?

    Best regards

    branar

    Hello

    Problem is solved using different fp (tsadpcvi.h, tsadpcvi.c). Instead of using tsapicvi.c with TestStand 4.2, the missing functions were found in tsadpcvi.c with TestStand 2010).

    Best regards

    branar

  • Creation of settings of variables / a module of code that persist when the sequence is complete

    I create parameters/variables programmatically in a module of code (c#) by passing the object to people of the country and calls the "NewSubProperty".

    I also tried SetValNumber with PropOption_InsertIfMissing.

    But it seems that they are only created in this instance of the sequence, because they left when the sequence is over. I really wanted to persist.

    I wanted to avoid creating the globals station dynamically like that, but maybe that's all I can do to make them last.

    Any ideas would be appreciated gratefully.

    Thank you

    Ronnie

    Hello

    Check out the links on this answer

    http://forums.NI.com/NI/board/message?board.ID=330&message.ID=11226&query.ID=267719#M11226

    It may be useful

    Concerning

    Ray Farmer

  • FPGA code with the evolution of the modules

    I need to create FPGA code to a cRIO-9072 facing the development of the modules.

    My cRIO will have a number any NI 9203 (analog acquisition) and modules OR 9411 (acquisition digital) as inserted by the operator. When turning the power on, the system must identify two possible modules were inserted in each of the slots. Subsequently, he will then know what choices of code to call to acquire data from the individual modules.

    I found the article in the knowledge base for CRY that queries each module and again reports the type of module and I can use it to successfully detect modules, but what LabVIEW fails to allow me to do this is to compile my FPGA code that was designed to deal with possible modules. After compiling, I get the error: "IO found point FPGA project. You must add the I/O item in the Project Explorer window, or select a different element in the control of FPGA of IO or the constant"because the compiler requires the appropriate modules are configured in the LabVIEW project. Unfortunately, this would require two different modules to be configured for each slot at the same time as there are sections of code for the 9203 modules and sections for 9411 modules for all eight locations coexist in a vi.

    Anyone have any ideas on how to get LabVIEW to compile my FPGA code somehow?

    Many thanks in advance,

    With the current draft of LabVIEW FPGA, you cannot compile a LabVIEW FPGA VI which manages several configurations of C Series modules.

    For your application, you must create a target of your project for each of the possible configurations of module and build the corresponding FPGA VI. Then, compile each of the screws to create the necessary for each configuration FPGA bitstream. Then in your host VI, you can detect what the current configuration of the module and download the binary stream appropriate for the FPGA. Another issue to consider is that the reference to the FPGA VI/bitstream returned by the open FPGA VI reference function will be unique to each bitstream/module configuration. So in your host VI, you'll need treat each configuration of the module with a separate set of code by contacting the FPGA.

    If you consider only two different modules and an eight slot chassis, there are 9 modules possible combinations. The condition would be to the end user to place all modules of the same type together, either from the left or the right side of the chassis.

Maybe you are looking for

  • Satellite M70: Memory 533 MHz with 667 Mhz compatibality?

    HelloI bought the new Satellite M70 (PSM70) 1.7 Ghz (400FSB) with the construction of memory DDR2 PC2 512 MB 533 MHz, if I DDR2 1 G 667 Mhz added to it? the Mhz will be a problem? and why the standard memory 533 Mhz and 400 Mhz processor speed? Kind

  • Dynadock U10 & Satellite Pro U400 (video display resolution - main monitor)

    Hi allI want to put in place the video driver Dynadock see the external monitor as primary monitor:I have difficulty option 'Mirror', but I can't change the resolution: it is set at 1280 x 1024 but I see 1280 x 800 (as in the laptop monitor) with the

  • Several DLL thread with a GUI

    I would like to create a DLL that is called within a c program.  The DLL would show a GUI that is updated when the C program passes 5 values.  The DLL would receive the values once every 0.1 s and update accordingly.  I wanted to use CVI, because as

  • Microsoft Money 2007 - when I click on files on USB, it says "read only".

    Microsoft Money - downloaded MM07 in order to open the files on my USB key from the previous account - when I click on the file I want to open, he said it is a read-only. How to 'read' this file

  • HP printer scanner

    I havea HPCM1312 MFP and it will only allow me to select BMP, PNG, JPG or TIF and not a PDF file.  What's wrong?