PageSourceSearch

https://www.passbolt.com/docs/assets/js/c3093437.9383f3d9.js

js passbolt.com collected 2026-09-24 08:41:28 UTC 7,084 bytes, 1 lines download raw bytes

1"use strict";(globalThis.webpackChunkpassbolt_docs||=[]).push([[1059],{95369(e,n,t){t.r(n),t.d(n,{assets:()=>d,contentTitle:()=>p,default:()=>y,frontMatter:()=>l,metadata:()=>i,toc:()=>c});const i=JSON.parse('{"id":"hosting/openpgp/generate-keys","title":"How to generate an OpenPGP key","description":"How to generate an OpenPGP key?","source":"@site/docs/hosting/openpgp/generate-keys.mdx","sourceDirName":"hosting/openpgp","slug":"/hosting/openpgp/generate-keys","permalink":"/docs/hosting/openpgp/generate-keys","draft":false,"unlisted":false,"editUrl":"https://github.com/passbolt/passbolt-docs/blob/main/docs/hosting/openpgp/generate-keys.mdx","tags":[],"version":"current","lastUpdatedAt":1781600508000,"frontMatter":{"title":"How to generate an OpenPGP key","description":"How to generate an OpenPGP key?","sidebar_label":"Generate OpenPGP Key","hide_table_of_contents":true},"sidebar":"hostingGuideSidebar","previous":{"title":"OpenPGP","permalink":"/docs/hosting/openpgp/"},"next":{"title":"Generate JWT Keys","permalink":"/docs/hosting/openpgp/generate-keys-jwt"}}');var r=t(74848),a=t(28453),s=t(83457),o=t(25515);const l={title:"How to generate an OpenPGP key",description:"How to generate an OpenPGP key?",sidebar_label:"Generate OpenPGP Key",hide_table_of_contents:!0},p=void 0,d={},c=[{value:"Requirements",id:"requirements",level:3},{value:"Generate a new OpenPGP key pair",id:"generate-a-new-openpgp-key-pair",level:3},{value:"Export an OpenPGP key pair",id:"export-an-openpgp-key-pair",level:3},{value:"Export an OpenPGP public key",id:"export-an-openpgp-public-key",level:4},{value:"Export an OpenPGP private key",id:"export-an-openpgp-private-key",level:4}];function h(e){const n={a:"a",admonition:"admonition",code:"code",h3:"h3",h4:"h4",li:"li",ol:"ol",p:"p",pre:"pre",strong:"strong",ul:"ul",...(0,a.R)(),...e.components};return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsxs)("div",{style:{display:"flex",gap:"1rem"},children:[(0,r.jsx)(o.A,{link:"https://www.passbolt.com/ce/docker",isUnderMainTitle:!0,children:"CE"}),(0,r.jsx)(o.A,{link:"https://www.passbolt.com/pricing/pro",isUnderMainTitle:!0,children:"Pro"})]}),"\n",(0,r.jsx)(n.h3,{id:"requirements",children:"Requirements"}),"\n",(0,r.jsx)(n.p,{children:"In order to follow this procedure, ensure you meet with the following minimum requirements:"}),"\n",(0,r.jsxs)(n.ul,{children:["\n",(0,r.jsx)(n.li,{children:"An access to a linux terminal machine"}),"\n",(0,r.jsx)(n.li,{children:"The OpenPGP package installed on the linux machine"}),"\n",(0,r.jsx)(n.li,{children:"The OpenPGP key to generate requirements: Algorithm, strength ..."}),"\n"]}),"\n",(0,r.jsx)(n.h3,{id:"generate-a-new-openpgp-key-pair",children:"Generate a new OpenPGP key pair"}),"\n",(0,r.jsxs)(n.admonition,{title:"Passphrase or no?",type:"caution",children:[(0,r.jsx)(n.p,{children:"Whether or not you need to set a passphrase will depend on why you are making this keypair."}),(0,r.jsxs)(n.p,{children:[(0,r.jsx)(n.strong,{children:"Organisation Account Recovery"}),": In this case you want to set a passphrase."]}),(0,r.jsxs)(n.p,{children:[(0,r.jsx)(n.strong,{children:"Server GPG keys"}),": In this case you do not want to set a passphrase."]})]}),"\n",(0,r.jsx)(n.p,{children:"Execute the following command to generate a new OpenPGP key pair."}),"\n",(0,r.jsx)(s.A,{children:"gpg --full-generate-key"}),"\n",(0,r.jsx)(n.p,{children:"This command will run an interactive wizard that will help you define the key settings:"}),"\n",(0,r.jsxs)(n.ol,{children:["\n",(0,r.jsx)(n.li,{children:"Select the key type, by instance: RSA."}),"\n",(0,r.jsx)(n.li,{children:"If RSA was chosen, select the keysize, by instance for a strong key: 3072."}),"\n",(0,r.jsx)(n.li,{children:'Select the expiration time, by instance for "no expiry": 0. Note that key expiration is not well handled by passbolt, set an expiration date only if you know what you are doing.'}),"\n",(0,r.jsx)(n.li,{children:"Confirm the key type information."}),"\n",(0,r.jsx)(n.li,{children:"Enter a name, by instance: Ada Lovelace."}),"\n",(0,r.jsxs)(n.li,{children:["Enter an email, by instance: ",(0,r.jsx)(n.a,{href:"mailto:[email protected]",children:"[email protected]"}),"."]}),"\n",(0,r.jsx)(n.li,{children:"Enter a comment, it is optional. It will only help you to identify a key in the keyring if similar name or email chosen."}),"\n",(0,r.jsx)(n.li,{children:"Confirm the key meta information."}),"\n",(0,r.jsx)(n.li,{children:"If you are creating an Organisation Account Recovery key pair set a passphrase, if this is for the server GPG key pair do not set a passphrase"}),"\n"]}),"\n",(0,r.jsx)(n.p,{children:"Once the key generated, the key will be stored in the keyring of the user you authenticated with and OpenPGP will output the details of the newly generated key."}),"\n",(0,r.jsx)(n.pre,{children:(0,r.jsx)(n.code,{className:"language-bash",children:"public and secret key created and signed.\n\npub   rsa3072 2022-08-04 [SC]\n      F5B94A730D636A18815046C1408B779FE1951A9A\
1nuid                      Ada Lovelace <[email protected]>\nsub   rsa3072 2022-07-28 [E]\n"})}),"\n",(0,r.jsxs)(n.p,{children:["The output contains a 40 characters long identifier (",(0,r.jsx)(n.code,{children:"F5B94A730D636A18815046C1408B779FE1951A9A"}),") that represents the key fingerprint, note it down, it will be useful later to identify the key in the keyring."]}),"\n",(0,r.jsx)(n.h3,{id:"export-an-openpgp-key-pair",children:"Export an OpenPGP key pair"}),"\n",(0,r.jsx)(n.h4,{id:"export-an-openpgp-public-key",children:"Export an OpenPGP public key"}),"\n",(0,r.jsxs)(n.p,{children:["Execute the following command to export a public key having ",(0,r.jsx)(n.code,{children:"F5B94A730D636A18815046C1408B779FE1951A9A"})," as fingerprint from the OpenPGP keyring into a file in armor format."]}),"\n",(0,r.jsx)(s.A,{children:"gpg --armor --export F5B94A730D636A18815046C1408B779FE1951A9A > public.key"}),"\n",(0,r.jsx)(n.h4,{id:"export-an-openpgp-private-key",children:"Export an OpenPGP private key"}),"\n",(0,r.jsxs)(n.p,{children:["Execute the following command to export a private key having ",(0,r.jsx)(n.code,{children:"F5B94A730D636A18815046C1408B779FE1951A9A"})," as fingerprint from the OpenPGP keyring into a file in armor format."]}),"\n",(0,r.jsx)(s.A,{children:"gpg --armor --export-secret-keys F5B94A730D636A18815046C1408B779FE1951A9A > private.key"})]})}function y(e={}){const{wrapper:n}={...(0,a.R)(),...e.components};return n?(0,r.jsx)(n,{...e,children:(0,r.jsx)(h,{...e})}):h(e)}},25515(e,n,t){t.d(n,{A:()=>c});var i=t(28774),r=t(5556),a=t.n(r);const s="chips_cpy_",o="link_WvDp",l="under-main-menu_SavF";var p=t(74848);const d=({children:e,link:n="",isUnderMainTitle:t=!1})=>{if(!e)return null;const r=n.length>0;return(0,p.jsx)("div",{className:`${t?l:""}`,children:r?(0,p.jsx)(i.A,{className:`${s} ${o}`,to:n,target:"_blank",children:e}):(0,p.jsx)("span",{className:s,children:e})})};d.propTypes={children:a().oneOfType([a().arrayOf(a().node),a().node]).isRequired,isUnderMainTitle:a().bool,link:a().string};const c=d}}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.