File: cloud-create-api-keypair.dita

package info (click to toggle)
virtualbox 7.1.12-dfsg-2
  • links: PTS, VCS
  • area: contrib
  • in suites: sid
  • size: 565,672 kB
  • sloc: ansic: 2,330,854; cpp: 2,193,228; asm: 230,777; python: 223,895; xml: 86,771; sh: 25,541; makefile: 8,158; perl: 5,697; java: 5,337; cs: 4,872; pascal: 1,782; javascript: 1,692; objc: 1,131; lex: 931; php: 906; sed: 899; yacc: 707
file content (55 lines) | stat: -rw-r--r-- 2,587 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
<?xml version='1.0' encoding='UTF-8'?>
<!DOCTYPE topic PUBLIC "-//OASIS//DTD DITA Topic//EN" "topic.dtd">
<topic xml:lang="en-us" id="cloud-create-api-keypair">
  <title>Creating an API Signing Key Pair</title>
  
  <body>
    <p>To use the cloud integration features of <ph conkeyref="vbox-conkeyref-phrases/product-name"/>, you must generate
      an API signing key pair that is used for API requests to <ph conkeyref="vbox-conkeyref-phrases/oci"/>. </p>
    <p>Your API requests are signed with your private key, and <ph conkeyref="vbox-conkeyref-phrases/oci"/> uses the
      public key to verify the authenticity of the request. You must upload the public key to the <ph
        conkeyref="vbox-conkeyref-phrases/oci"/> Console. </p>
    <note>
      <p>
          This key pair is not the same SSH key that you use to access
          compute instances on <ph conkeyref="vbox-conkeyref-phrases/oci"/>.
        </p>
    </note>
    <ol>
      <li>
        <p>(Optional) Create a <filepath>.oci</filepath> directory to store the key pair. </p>
        <pre xml:space="preserve">$ mkdir ~/.oci</pre>
        <p>The key pair is usually installed in the <filepath>.oci</filepath> folder in your home directory. For
          example, <filepath>~/.oci</filepath> on a Linux system. </p>
      </li>
      <li>
        <p>Generate the private key. </p>
        <p>Use the <codeph>openssl</codeph> command. </p>
        <ul>
          <li>
            <p> To generate a private key with a passphrase (prompt for passphrase): </p>
            <pre xml:space="preserve">$ openssl genrsa -out ~/.oci/oci_api_key.pem -aes256 2048 </pre>
          </li>
          <li>
            <p> To generate a private key with a passphrase entered on the command line as an argument:</p>
            <pre xml:space="preserve">$ openssl genrsa -aes256 -passout pass:user_passphrase -out ~/.oci/oci_api_key.pem 2048</pre>
          </li>
          <li>
            <p>
                To generate a private key without a passphrase:
              </p>
            <pre xml:space="preserve">$ openssl genrsa -out ~/.oci/oci_api_key.pem 2048</pre>
          </li>
        </ul>
      </li>
      <li>
        <p>Change permissions for the private key. </p>
        <pre xml:space="preserve">$ chmod 600 ~/.oci/oci_api_key.pem</pre>
        <p>Generate the public key. </p>
        <pre xml:space="preserve">$ openssl rsa -pubout -in ~/.oci/oci_api_key.pem -out ~/.oci/oci_api_key_public.pem</pre>
        <p>Enter the passphrase when prompted, if you set one.</p>
      </li>
    </ol>
  </body>
  
</topic>