{"id":66,"date":"2025-03-05T06:19:46","date_gmt":"2025-03-05T06:19:46","guid":{"rendered":"https:\/\/documentation.iqonic.design\/streamit-tv\/?p=66"},"modified":"2025-06-12T10:20:32","modified_gmt":"2025-06-12T10:20:32","slug":"how-to-generate-a-new-jks-keystore","status":"publish","type":"post","link":"https:\/\/documentation.iqonic.design\/streamit-tv-app\/how-to-generate-a-new-jks-keystore\/","title":{"rendered":"How to generate a new JKS\/Keystore?"},"content":{"rendered":"<div class=\"nolwrap\">\n<h3 class=\"wp-block-heading\"><strong>Generate a new JKS\/Keystore<\/strong><\/h3>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Method 1 &#8211; Using Terminal<\/strong><\/h2>\n\n\n\n<p>1. Run the following command in your terminal<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">   keytool -genkey -v -keystore android\/&lt;JKS FILE NAME&gt;.jks -alias &lt;ALIAS NAME&gt; -keyalg RSA -keysize 2048 -validity 10000<\/pre>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Example command:<\/li>\n<\/ul>\n\n\n\n<pre class=\"wp-block-preformatted\">  keytool -genkey -v -keystore android\/example.jks -alias example -keyalg RSA -keysize 2048 -validity 10000<\/pre>\n\n\n\n<p>Here,<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>JKS File Name: example<\/li>\n\n\n\n<li>Alias Name: example<\/li>\n<\/ul>\n\n\n\n<p>The command will generate a JKS file in your android directory of Project. The validity of the keystore certificate is set to 10,000 days. If you don&#8217;t add &#8220;-validity&nbsp;<code>&lt;NumberOfDays&gt;<\/code>&#8220;, the default value will be 90 days.<\/p>\n\n\n\n<p><strong>Note:<\/strong>&nbsp;If you encounter an error like &#8216;Command &#8216;keytool&#8217; not found&#8217;, you&#8217;ll also receive a suggestion to install keytool. Follow the suggestion and execute the command to install &#8216;keytool&#8217;.<\/p>\n\n\n\n<p>After installing keytool, run the &#8216;keytool&#8217; command again and complete the process again.<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"1206\" height=\"373\" src=\"https:\/\/documentation.iqonic.design\/streamit-tv\/wp-content\/uploads\/sites\/8\/2025\/03\/jks_cmd.png\" alt=\"\" class=\"wp-image-295\" \/><\/figure>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Method 2 &#8211; Using Android Studio<\/strong><\/h2>\n\n\n\n<p>1. Open your Android module. Wait for a while to complete the import process for the &#8216;android&#8217; Gradle project.<\/p>\n\n\n\n<p>2.Open the&nbsp;<strong>build<\/strong>&nbsp;menu from the Menu bar and Select&nbsp;<strong>Generate Signed Bundle\/APK<\/strong>.&nbsp;<strong>Choose APK<\/strong>&nbsp;and click&nbsp;<strong>Next<\/strong>.<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"631\" height=\"636\" src=\"https:\/\/documentation.iqonic.design\/streamit-tv\/wp-content\/uploads\/sites\/8\/2025\/03\/jks1.png\" alt=\"\" class=\"wp-image-290\" \/><\/figure>\n\n\n\n<p><\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"541\" height=\"481\" src=\"https:\/\/documentation.iqonic.design\/streamit-tv\/wp-content\/uploads\/sites\/8\/2025\/03\/jks2.png\" alt=\"\" class=\"wp-image-291\" \/><\/figure>\n\n\n\n<p>3.In the resulting dialog, for the Key store path field, choose&nbsp;<strong>Create New<\/strong>&nbsp;to open the&nbsp;<strong>New Key Store<\/strong>&nbsp;dialog.<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"541\" height=\"481\" src=\"https:\/\/documentation.iqonic.design\/streamit-tv\/wp-content\/uploads\/sites\/8\/2025\/03\/jks3.png\" alt=\"\" class=\"wp-image-292\" \/><\/figure>\n\n\n\n<p>When you click on&nbsp;<strong>Create New<\/strong>&nbsp;it will open a dialog to choose keystore file.<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Choose the path where you want to store your&nbsp;<strong>keystore<\/strong>\/<strong>jks<\/strong>&nbsp;file. In this example we&#8217;re storing it at&nbsp;<strong>android<\/strong>&nbsp;directory of Project.You can choose path where you want to store it.<\/li>\n\n\n\n<li>Just Add keystore filename in&nbsp;<strong>File name<\/strong>&nbsp;field.<\/li>\n<\/ul>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"484\" height=\"609\" src=\"https:\/\/documentation.iqonic.design\/streamit-tv\/wp-content\/uploads\/sites\/8\/2025\/03\/jks4.png\" alt=\"\" class=\"wp-image-293\" \/><\/figure>\n\n\n\n<p>4. Add&nbsp;<strong>Keystore Password<\/strong>,&nbsp;<strong>Key Alias<\/strong>&nbsp;,&nbsp;<strong>Alias Password<\/strong>. Add Details in Certificate section then press&nbsp;<strong>Ok<\/strong>.<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"569\" height=\"680\" src=\"https:\/\/documentation.iqonic.design\/streamit-tv\/wp-content\/uploads\/sites\/8\/2025\/03\/jks5.png\" alt=\"\" class=\"wp-image-294\" \/><\/figure>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>INFO<\/strong><\/h3>\n\n\n\n<p>These&nbsp;<strong>Keystore File Path<\/strong>,<strong>Keystore Password<\/strong>,&nbsp;<strong>Key Alias<\/strong>&nbsp;,&nbsp;<strong>Alias Password<\/strong>, you&#8217;ve to set in keystore.properties file which will be in&nbsp;<strong>android<\/strong>&nbsp;directory of project. If it&#8217;s not available then just right click on android directory \u2192 New \u2192 File and name it as &#8216;key.properties&#8217;. Then you can perform steps mentioned&nbsp;<a href=\"https:\/\/documentation.iqonic.design\/streamit-tv-app\/app-faqs\/how-to-generate-the-sha-in-android-studio\">here<\/a><\/p>\n\n\n\n<p><\/p>\n<\/div>","protected":false},"excerpt":{"rendered":"<p>Generate a new JKS\/Keystore Method 1 &#8211; Using Terminal 1. Run the following command in your terminal keytool -genkey -v -keystore android\/&lt;JKS FILE NAME&gt;.jks -alias &lt;ALIAS NAME&gt; -keyalg RSA -keysize 2048 -validity 10000 keytool -genkey -v -keystore android\/example.jks -alias example -keyalg RSA -keysize 2048 -validity 10000 Here, The command will generate a JKS file in [&hellip;]<\/p>\n","protected":false},"author":11,"featured_media":0,"parent":60,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-66","post","type-post","status-publish","format-standard","hentry","category-streamittv"],"featured_image_src":null,"author_info":{"display_name":"laraveladminiq","author_link":"https:\/\/documentation.iqonic.design\/streamit-tv-app\/author\/laraveladminiq\/"},"children":[],"_links":{"self":[{"href":"https:\/\/documentation.iqonic.design\/streamit-tv-app\/wp-json\/wp\/v2\/posts\/66","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/documentation.iqonic.design\/streamit-tv-app\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/documentation.iqonic.design\/streamit-tv-app\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/documentation.iqonic.design\/streamit-tv-app\/wp-json\/wp\/v2\/users\/11"}],"replies":[{"embeddable":true,"href":"https:\/\/documentation.iqonic.design\/streamit-tv-app\/wp-json\/wp\/v2\/comments?post=66"}],"version-history":[{"count":6,"href":"https:\/\/documentation.iqonic.design\/streamit-tv-app\/wp-json\/wp\/v2\/posts\/66\/revisions"}],"predecessor-version":[{"id":625,"href":"https:\/\/documentation.iqonic.design\/streamit-tv-app\/wp-json\/wp\/v2\/posts\/66\/revisions\/625"}],"up":[{"embeddable":true,"href":"https:\/\/documentation.iqonic.design\/streamit-tv-app\/wp-json\/wp\/v2\/posts\/60"}],"wp:attachment":[{"href":"https:\/\/documentation.iqonic.design\/streamit-tv-app\/wp-json\/wp\/v2\/media?parent=66"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/documentation.iqonic.design\/streamit-tv-app\/wp-json\/wp\/v2\/categories?post=66"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/documentation.iqonic.design\/streamit-tv-app\/wp-json\/wp\/v2\/tags?post=66"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}