SSH to the Blackberry Z10 (BB10) Guide

There are at least two ways for getting shell access to the BB10’s QNX layer. For both we rely on the Blackberry Native SDK set of tools, available as a free download on RIM’s website. One takes advantage of the QNX Momentics IDE and is easy as click and go, the other is more old school, involving command line , but also gives a better insight and control.

Common part

Take the BB10 device, go to Settings->Security and Privacy->Development Mode . Turn on Development Mode.
BB10_development_mode_1 BB10_development_mode_2 BB10_development_mode_3 BB10_development_mode_4
And now for the interesting part, getting SSH access:

1. Using QNX Momentics IDE

Having the IDE installed and the BB10 connected to the computer, go to Window->Open perspective->QNX System Information:
If “Target Navigator” is not visible, toggle it from Window->Show View->Target Navigator.
Right click the device listed there, and select Launch SSH Session.
A SSH connection is now open, as devuser , a non privileged user account, and you can start using the shell.
Alternatively you can open the terminal in the Standard C/C++ Perspective View,
by going to Window->Show View->Other, and select Terminal, that will show up tabbed in the bottom menu
qnx_momentics_ide_4 qnx_momentics_ide_5

2. Using Command line, blackberry-connect, own SSH2-RSA keys and a SSH client (putty)

Step 1: Download PUTTY if you don’t already have it.
Step 2: Open PUTTYGEN, select type of key SSH-2 RSA, and number of bits in a generated key 4096. Press Generate and move the mouse to create random events.
Select the text under “Public key for pasting into OpenSSH authorized_keys file:”, from the start to the last equal (=) sign, and save it to a file, let’s name it pubkeyfile.
Save public key and private key, without entering any key passphrase, let’s name them and key.ppk
So now you have three files,, key.ppk and pubkeyfile.
Step 3: Having the Blackberry Native SDK tools installed, go to the location, start a command prompt / shell where you must run bbndk-env.bat / . Make sure the three files generated at step 2 are in the same location, for convenience. Type:

blackberry-connect -password 1234 -sshPublicKey pubkeyfile

Where 1234 is the BB10 password set when you enabled development mode.
If you are getting “Error: A network error occurred while communicating with the target.” you need to disconnect the device in QNX IDE first, by right clicking the USB target ->Blackberry tools->Disconnect
With blackberry-connect successful you’ll get something similar to:
Leave the window opened as instructed.
Step 4: In a new command prompt/ shell, type

putty.exe -i key.ppk -ssh devuser@

If everything goes well, you’ll get putty connected!
Remember, this can be used for sending files as well, via sftp. Good luck!

This article has 3 Comments

  1. Hi RT, you won’t get enhanced privileges for any of the above. For option 2, you get devuser privileges.

  2. Very cool! Was just browsing around and was a bit bored. Tried this out and yep it works.

Leave a Reply