{"id":1418,"date":"2019-03-11T13:18:31","date_gmt":"2019-03-11T13:18:31","guid":{"rendered":"https:\/\/www.genesesofts.com\/?p=1418"},"modified":"2020-11-02T02:15:10","modified_gmt":"2020-11-02T02:15:10","slug":"create-a-self-signed-ssl-certificate-and-upload-on-aws-account","status":"publish","type":"post","link":"https:\/\/www.genesesolution.com\/bd\/blog\/create-a-self-signed-ssl-certificate-and-upload-on-aws-account\/","title":{"rendered":"Create a self-signed SSL Certificate and upload on AWS Account"},"content":{"rendered":"\n[et_pb_section bb_built=&#8221;1&#8243; specialty=&#8221;on&#8221; _builder_version=&#8221;3.0.47&#8243;][et_pb_column type=&#8221;3_4&#8243; specialty_columns=&#8221;3&#8243;][et_pb_row_inner admin_label=&#8221;Row&#8221; _builder_version=&#8221;3.0.47&#8243;][et_pb_column_inner type=&#8221;4_4&#8243; saved_specialty_column_type=&#8221;3_4&#8243;][et_pb_text _builder_version=&#8221;3.19.14&#8243;]\n\n<p><span style=\"font-weight: 400;\">Security is a critically important factor in the success of any website. You need to set up a security certificate so that your server data will be secure. SSL certificates are a set of small data which binds a cryptographic key to an organization&#8217;s details. <\/span><\/p><p><span style=\"font-weight: 400;\">When you set this up, you have the option of creating a self-signed certificate or creating a certificate approved by a certificate authority. <\/span><\/p><p><span style=\"font-weight: 400;\">Whether you sign a certificate yourself or get one signed by a certificate authority, both establish a secure connection between web server and browser and encrypted data is sent over an HTTPS connection. Basically, self-signed certificates are ideal for a test environment, where you need to test over an HTTPS connection and don\u2019t want to pay for the certificate authority.<\/span><\/p><p><span style=\"font-weight: 400;\">This article mainly focuses on creating a self-signed certificate which will need the following:<\/span><\/p><ul><li style=\"font-weight: 400;\"><span style=\"font-weight: 400;\">A Public Key<\/span><\/li><li style=\"font-weight: 400;\"><span style=\"font-weight: 400;\">A Private Key<\/span><\/li><li style=\"font-weight: 400;\"><span style=\"font-weight: 400;\">A Certificate Signing Request (CSR)<\/span><\/li><\/ul><p><img src=\"http:\/\/genesesolution.com\/wp-content\/uploads\/sites\/4\/2020\/06\/amazon-web-services-ssl-certificate.png\" alt=\"Image result for aws ssl certificate\" \/><\/p><p><span style=\"font-weight: 400;\">Security is a critically important factor in the success of any website. You need to set up a security certificate so that your server data will be secure. SSL certificates are a set of small data which binds a cryptographic key to an organization&#8217;s details. <\/span><\/p><p><span style=\"font-weight: 400;\">When you set this up, you have the option of creating a self-signed certificate or creating a certificate approved by a certificate authority. <\/span><\/p><p><span style=\"font-weight: 400;\">Whether you sign a certificate yourself or get one signed by a certificate authority, both establish a secure connection between web server and browser and encrypted data is sent over an HTTPS connection. Basically, self-signed certificates are ideal for a test environment, where you need to test over an HTTPS connection and don\u2019t want to pay for the certificate authority.<\/span><\/p><p><span style=\"font-weight: 400;\">This article mainly focuses on creating a self-signed certificate which will need the following:<\/span><\/p><ul><li style=\"font-weight: 400;\"><span style=\"font-weight: 400;\">A Public Key<\/span><\/li><li style=\"font-weight: 400;\"><span style=\"font-weight: 400;\">A Private Key<\/span><\/li><li style=\"font-weight: 400;\"><span style=\"font-weight: 400;\">A Certificate Signing Request (CSR)<\/span><\/li><\/ul><p><span style=\"font-weight: 400;\">The Private and Public Keys are a part of encryption to encode information that will be transmitted. Both keys work in symmetric and asymmetric encryption. Asymmetric encryption uses both private and public keys for better security. The sender sends a message that is encrypted using public key and receiver decrypts it using the private key. However, in symmetric encryption, the same key i.e private key is used to encrypt as well as decrypt the message.<\/span><\/p><p>\u00a0<\/p><h2><b>The Process<\/b><\/h2><p><span style=\"font-weight: 400;\">You can use <\/span><b>OpenSSL<\/b><span style=\"font-weight: 400;\"> toolkit to generate the encryption keys and CSR. The first step would be to create a 2048 bit RSA key stored in PEM format so that it is readable as ASCII text. Use the following command in a Linux command line already configured with OpenSSL.<\/span><\/p><blockquote><p><i><span style=\"font-weight: 400;\">openssl genrsa -out private.pem 2048<\/span><\/i><\/p><\/blockquote><p><span style=\"font-weight: 400;\">Next up, to create a public key (public.pem), use the following command,<\/span><\/p><blockquote><p><i><span style=\"font-weight: 400;\">openssl rsa -in private.pem -outform PEM -pubout -out public.pem<\/span><\/i><\/p><\/blockquote><p><span style=\"font-weight: 400;\">Once the encryption keys are created, you can proceed on creating a Certificate Signing Request (CSR). When generating a CSR, you will be prompted to provide additional information regarding the certificate.<\/span><\/p><blockquote><p><i><span style=\"font-weight: 400;\">openssl req -new -key private.pem -out certificate.csr<\/span><\/i><\/p><\/blockquote><p><span style=\"font-weight: 400;\">Now you have your private key as well as the CSR, you can issue the following command to create your own self-signed certificate.<\/span><\/p><blockquote><p><i><span style=\"font-weight: 400;\">openssl x509 -req -days 365 -in certificate.csr -signkey private.pem -out certificate.crt<\/span><\/i><\/p><\/blockquote><p>\u00a0<\/p><h2><b>Uploading the certificate to AWS<\/b><\/h2><p><span style=\"font-weight: 400;\">Now you have created an SSL certificate and it&#8217;s time to upload it to AWS. Use the <\/span><b>AWS CLI <\/b><span style=\"font-weight: 400;\">to upload the certificate. Therefore the AWS CLI should be pre-configured. Then, you can use the following command to upload the certificate.<\/span><\/p><blockquote><p><i><span style=\"font-weight: 400;\">aws iam upload-server-certificate &#8211;server-certificate-name my-server-test &#8211;certificate-body file:\/\/certificate.crt &#8211;private-key file:\/\/private.pem<\/span><\/i><\/p><\/blockquote>\n\n[\/et_pb_text][\/et_pb_column_inner][\/et_pb_row_inner][\/et_pb_column][et_pb_column type=&#8221;1_4&#8243;][et_pb_sidebar area=&#8221;sidebar-1&#8243; _builder_version=&#8221;3.15&#8243; \/][\/et_pb_column][\/et_pb_section]\n","protected":false},"excerpt":{"rendered":"<p>Whether you sign a certificate yourself or get one signed by a certificate authority, both establish a secure connection between web server and browser and encrypted data is sent over an HTTPS connection.<\/p>\n","protected":false},"author":21,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_et_pb_use_builder":"on","_et_pb_old_content":"","_et_gb_content_width":"","_links_to":"","_links_to_target":""},"categories":[70,73,76],"tags":[17,52],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v16.8 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Create a self-signed SSL Certificate and upload on AWS Account<\/title>\n<meta name=\"description\" content=\"SSL Certificate, SSL establishes a secure connection between the web server and the browser and encrypted data is sent over an HTTPS connection.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.genesesolution.com\/bd\/blog\/create-a-self-signed-ssl-certificate-and-upload-on-aws-account\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Create a self-signed SSL Certificate and upload on AWS Account\" \/>\n<meta property=\"og:description\" content=\"Whether you sign a certificate yourself or get one signed by a certificate authority, both establish a secure connection between web server and browser and encrypted data is sent over an HTTPS connection.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.genesesolution.com\/bd\/blog\/create-a-self-signed-ssl-certificate-and-upload-on-aws-account\/\" \/>\n<meta property=\"og:site_name\" content=\"Genese Solution Bangladesh\" \/>\n<meta property=\"article:published_time\" content=\"2019-03-11T13:18:31+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2020-11-02T02:15:10+00:00\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:title\" content=\"Create a self-signed SSL Certificate and upload on AWS Account\" \/>\n<meta name=\"twitter:description\" content=\"Whether you sign a certificate yourself or get one signed by a certificate authority, both establish a secure connection between web server and browser and encrypted data is sent over an HTTPS connection.\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Anjani Phuyal\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"3 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.genesesolution.com\/bd\/#website\",\"url\":\"https:\/\/www.genesesolution.com\/bd\/\",\"name\":\"Genese Solution Bangladesh\",\"description\":\"Creating you the best\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.genesesolution.com\/bd\/?s={search_term_string}\"},\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"en-US\"},{\"@type\":\"ImageObject\",\"@id\":\"https:\/\/www.genesesolution.com\/bd\/blog\/create-a-self-signed-ssl-certificate-and-upload-on-aws-account\/#primaryimage\",\"inLanguage\":\"en-US\",\"url\":\"\",\"contentUrl\":\"\"},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.genesesolution.com\/bd\/blog\/create-a-self-signed-ssl-certificate-and-upload-on-aws-account\/#webpage\",\"url\":\"https:\/\/www.genesesolution.com\/bd\/blog\/create-a-self-signed-ssl-certificate-and-upload-on-aws-account\/\",\"name\":\"Create a self-signed SSL Certificate and upload on AWS Account\",\"isPartOf\":{\"@id\":\"https:\/\/www.genesesolution.com\/bd\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/www.genesesolution.com\/bd\/blog\/create-a-self-signed-ssl-certificate-and-upload-on-aws-account\/#primaryimage\"},\"datePublished\":\"2019-03-11T13:18:31+00:00\",\"dateModified\":\"2020-11-02T02:15:10+00:00\",\"author\":{\"@id\":\"https:\/\/www.genesesolution.com\/bd\/#\/schema\/person\/9474e5780afd73d843feb813d4a18e71\"},\"description\":\"SSL Certificate, SSL establishes a secure connection between the web server and the browser and encrypted data is sent over an HTTPS connection.\",\"breadcrumb\":{\"@id\":\"https:\/\/www.genesesolution.com\/bd\/blog\/create-a-self-signed-ssl-certificate-and-upload-on-aws-account\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.genesesolution.com\/bd\/blog\/create-a-self-signed-ssl-certificate-and-upload-on-aws-account\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.genesesolution.com\/bd\/blog\/create-a-self-signed-ssl-certificate-and-upload-on-aws-account\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/www.genesesolution.com\/bd\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Create a self-signed SSL Certificate and upload on AWS Account\"}]},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.genesesolution.com\/bd\/#\/schema\/person\/9474e5780afd73d843feb813d4a18e71\",\"name\":\"Anjani Phuyal\",\"image\":{\"@type\":\"ImageObject\",\"@id\":\"https:\/\/www.genesesolution.com\/bd\/#personlogo\",\"inLanguage\":\"en-US\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/63136611a134b1d39e4f160d67576cd3?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/63136611a134b1d39e4f160d67576cd3?s=96&d=mm&r=g\",\"caption\":\"Anjani Phuyal\"},\"url\":\"https:\/\/www.genesesolution.com\/bd\/blog\/author\/anjani\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Create a self-signed SSL Certificate and upload on AWS Account","description":"SSL Certificate, SSL establishes a secure connection between the web server and the browser and encrypted data is sent over an HTTPS connection.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.genesesolution.com\/bd\/blog\/create-a-self-signed-ssl-certificate-and-upload-on-aws-account\/","og_locale":"en_US","og_type":"article","og_title":"Create a self-signed SSL Certificate and upload on AWS Account","og_description":"Whether you sign a certificate yourself or get one signed by a certificate authority, both establish a secure connection between web server and browser and encrypted data is sent over an HTTPS connection.","og_url":"https:\/\/www.genesesolution.com\/bd\/blog\/create-a-self-signed-ssl-certificate-and-upload-on-aws-account\/","og_site_name":"Genese Solution Bangladesh","article_published_time":"2019-03-11T13:18:31+00:00","article_modified_time":"2020-11-02T02:15:10+00:00","twitter_card":"summary_large_image","twitter_title":"Create a self-signed SSL Certificate and upload on AWS Account","twitter_description":"Whether you sign a certificate yourself or get one signed by a certificate authority, both establish a secure connection between web server and browser and encrypted data is sent over an HTTPS connection.","twitter_misc":{"Written by":"Anjani Phuyal","Est. reading time":"3 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebSite","@id":"https:\/\/www.genesesolution.com\/bd\/#website","url":"https:\/\/www.genesesolution.com\/bd\/","name":"Genese Solution Bangladesh","description":"Creating you the best","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.genesesolution.com\/bd\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"en-US"},{"@type":"ImageObject","@id":"https:\/\/www.genesesolution.com\/bd\/blog\/create-a-self-signed-ssl-certificate-and-upload-on-aws-account\/#primaryimage","inLanguage":"en-US","url":"","contentUrl":""},{"@type":"WebPage","@id":"https:\/\/www.genesesolution.com\/bd\/blog\/create-a-self-signed-ssl-certificate-and-upload-on-aws-account\/#webpage","url":"https:\/\/www.genesesolution.com\/bd\/blog\/create-a-self-signed-ssl-certificate-and-upload-on-aws-account\/","name":"Create a self-signed SSL Certificate and upload on AWS Account","isPartOf":{"@id":"https:\/\/www.genesesolution.com\/bd\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.genesesolution.com\/bd\/blog\/create-a-self-signed-ssl-certificate-and-upload-on-aws-account\/#primaryimage"},"datePublished":"2019-03-11T13:18:31+00:00","dateModified":"2020-11-02T02:15:10+00:00","author":{"@id":"https:\/\/www.genesesolution.com\/bd\/#\/schema\/person\/9474e5780afd73d843feb813d4a18e71"},"description":"SSL Certificate, SSL establishes a secure connection between the web server and the browser and encrypted data is sent over an HTTPS connection.","breadcrumb":{"@id":"https:\/\/www.genesesolution.com\/bd\/blog\/create-a-self-signed-ssl-certificate-and-upload-on-aws-account\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.genesesolution.com\/bd\/blog\/create-a-self-signed-ssl-certificate-and-upload-on-aws-account\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.genesesolution.com\/bd\/blog\/create-a-self-signed-ssl-certificate-and-upload-on-aws-account\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.genesesolution.com\/bd\/"},{"@type":"ListItem","position":2,"name":"Create a self-signed SSL Certificate and upload on AWS Account"}]},{"@type":"Person","@id":"https:\/\/www.genesesolution.com\/bd\/#\/schema\/person\/9474e5780afd73d843feb813d4a18e71","name":"Anjani Phuyal","image":{"@type":"ImageObject","@id":"https:\/\/www.genesesolution.com\/bd\/#personlogo","inLanguage":"en-US","url":"https:\/\/secure.gravatar.com\/avatar\/63136611a134b1d39e4f160d67576cd3?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/63136611a134b1d39e4f160d67576cd3?s=96&d=mm&r=g","caption":"Anjani Phuyal"},"url":"https:\/\/www.genesesolution.com\/bd\/blog\/author\/anjani\/"}]}},"_links":{"self":[{"href":"https:\/\/www.genesesolution.com\/bd\/wp-json\/wp\/v2\/posts\/1418"}],"collection":[{"href":"https:\/\/www.genesesolution.com\/bd\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.genesesolution.com\/bd\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.genesesolution.com\/bd\/wp-json\/wp\/v2\/users\/21"}],"replies":[{"embeddable":true,"href":"https:\/\/www.genesesolution.com\/bd\/wp-json\/wp\/v2\/comments?post=1418"}],"version-history":[{"count":1,"href":"https:\/\/www.genesesolution.com\/bd\/wp-json\/wp\/v2\/posts\/1418\/revisions"}],"predecessor-version":[{"id":6438,"href":"https:\/\/www.genesesolution.com\/bd\/wp-json\/wp\/v2\/posts\/1418\/revisions\/6438"}],"wp:attachment":[{"href":"https:\/\/www.genesesolution.com\/bd\/wp-json\/wp\/v2\/media?parent=1418"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.genesesolution.com\/bd\/wp-json\/wp\/v2\/categories?post=1418"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.genesesolution.com\/bd\/wp-json\/wp\/v2\/tags?post=1418"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}