Skip Headers
Oracle® Fusion Middleware User's Guide for Oracle JRockit Virtual Edition
11g Release 1 (11.1.1.3.1)

Part Number E15206-03
Go to Documentation Home
Home
Go to Table of Contents
Contents
Go to Feedback page
Contact Us

Go to previous page
Previous
Go to next page
Next
View PDF

5.2 Configuring the SSH Service

You can configure the SSH service for password-based authentication and public key-based authentication.

5.2.1 Configuring the SSH Service for Password-Based Authentication

In this form of authentication, a user name and password must be used to log in to the SSH service in the virtual machine.

Prerequisite

Enable the SSH service as described in Section 5.1.

Procedure

To configure the SSH service for password-based authentication, do the following:

  1. Shut down the virtual machine.

  2. Add a user for the SSH service by running the following command:

    java -jar jrockitve-imagetool.jar --reconfigure-service vm_cfg sshd add user user_name
    

    In this command, vm_cfg represents the path and name of the configuration file (vm.cfg) corresponding to the virtual machine, and user_name represents a user who can access the sshd service.

  3. At the prompt, enter a password for the user and confirm the password.

5.2.2 Configuring the SSH Service for Public Key Authentication

Public key authentication is potentially more secure than password-based authentication, but it is more difficult to set up. You must generate a public-private key pair, add the public key to the sshd service in the virtual machine, and specify the private key while logging to the service.

Prerequisites

  • Generate an SSH-2 RSA-compliant public-private key pair by using a key-generator tool such as PuTTY or the ssh-keygen command, and save the keys.

  • Enable the SSH service as described in Section 5.1.

Procedure

To configure the SSH service for public key-based authentication do the following:

  1. Shut down the virtual machine.

  2. Add the public key to the sshd service by running the following command:

    java -jar jrockitve-imagetool.jar --reconfigure-service vm_cfg sshd add key keyfile
    

    In this command, vm_cfg represents the path and name of the configuration file (vm.cfg) corresponding to the virtual machine, and keyfile represents the path and name of the file in which you saved the generated public key.