# Create a self-signed certificate

{% hint style="info" %}
In the root folder of the ***GameLauncher-FlatWindow***\
Open the **MAC\_AppGenerator** folder\
![](https://4090346021-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FOQCKadC4SNL7ML9xwPi2%2Fuploads%2F97ZHunTdOBa0EEXS0hIw%2Fimage.png?alt=media\&token=9ec85c76-61ce-4525-89a8-16cd65446aad)
{% endhint %}

1. In **Finder** -> Locate and open **KeyChain Access**

<div align="left"><figure><img src="https://4090346021-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FOQCKadC4SNL7ML9xwPi2%2Fuploads%2F4Gqrznn4reTEWjTzygV4%2Fimage.png?alt=media&#x26;token=0fbb0ef4-dbc4-4ea3-9d41-353356980c34" alt=""><figcaption></figcaption></figure></div>

2. **In the top menu -> KeyChain Access -> Certificate Assistant -> Create Certificate**

<div align="left"><figure><img src="https://4090346021-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FOQCKadC4SNL7ML9xwPi2%2Fuploads%2FmRplTnIZzlMVmvo1ZXnJ%2Fimage.png?alt=media&#x26;token=a839b148-5af2-4cae-a696-d04acc1fcc9f" alt=""><figcaption></figcaption></figure></div>

3. In the **Certificate Assistant** set this data and click **Continue**

> **Name:** *GameLauncher*\
> **Identity Type:** *Self Signed Root*\
> **Certificate Type:** *Code Signing*\
> **Let me override defaults:** *(checked)*

<figure><img src="https://4090346021-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FOQCKadC4SNL7ML9xwPi2%2Fuploads%2FcpwrdzCiN6FtsUhWwlgg%2Fimage.png?alt=media&#x26;token=b5b71b1e-5490-4e12-a126-8503550b020c" alt=""><figcaption></figcaption></figure>

4. &#x20;Set the **Validity Period** to 2000 days

   <div align="left"><figure><img src="https://4090346021-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FOQCKadC4SNL7ML9xwPi2%2Fuploads%2FBhqzYafi8YfqcfHnPtuD%2Fimage.png?alt=media&#x26;token=196817d8-3f2f-4311-be03-cc83e55c7757" alt=""><figcaption></figcaption></figure></div>
5. In the **Certificate Information**

> **Email Address:** *with your email*\
> **Name:** *GameLauncher*\
> **Organization:** *GameLauncher inc*\
> Country or Region: *your country*

<figure><img src="https://4090346021-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FOQCKadC4SNL7ML9xwPi2%2Fuploads%2FuXDnVnsPO5RFmzoL8t2k%2Fimage.png?alt=media&#x26;token=173c8499-41a4-474c-8120-fa4f9a917a00" alt=""><figcaption></figcaption></figure>

6. **Key Pair Information** -> **Continue**

<figure><img src="https://4090346021-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FOQCKadC4SNL7ML9xwPi2%2Fuploads%2FSyy8uPFqYQc28laN9NdG%2Fimage.png?alt=media&#x26;token=19d0c0ac-b613-4e3d-a923-66e13e60d19d" alt=""><figcaption></figcaption></figure>

7. In **Key Usage Extension** set this data:

> **Capabilities**\
> Signature\
> Certificate Signing

<div align="left"><figure><img src="https://4090346021-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FOQCKadC4SNL7ML9xwPi2%2Fuploads%2FwzAFiBTwKwGfjNIWKLJY%2Fimage.png?alt=media&#x26;token=31368c84-249e-457a-b630-81db70bd2188" alt=""><figcaption></figcaption></figure></div>

8. **Extended Key Usage Extension -> Continue**

<div align="left"><figure><img src="https://4090346021-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FOQCKadC4SNL7ML9xwPi2%2Fuploads%2Fq1yjJDq6IJ5Hz13X3TDv%2Fimage.png?alt=media&#x26;token=64bcc9a6-2f16-4742-849f-8329eb61c934" alt=""><figcaption></figcaption></figure></div>

9. **Basic Constraints Extension -> Continue**

<div align="left" data-full-width="false"><figure><img src="https://4090346021-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FOQCKadC4SNL7ML9xwPi2%2Fuploads%2FHF9IyozoqiUmJ4poBSnS%2Fimage.png?alt=media&#x26;token=ad753535-9ba4-4a59-a97a-526e3e3a6fb4" alt=""><figcaption></figcaption></figure></div>

10. **Subject Alternate Name Extension -> Continue**

<figure><img src="https://4090346021-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FOQCKadC4SNL7ML9xwPi2%2Fuploads%2F8XOEaw82y9URVpTj4O0J%2Fimage.png?alt=media&#x26;token=322f9716-8936-4bd8-afb5-1b49f721b1f1" alt=""><figcaption></figcaption></figure>

11. **Specify a Location For The Certificate -> Create**

<figure><img src="https://4090346021-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FOQCKadC4SNL7ML9xwPi2%2Fuploads%2FhKQtNKrMlXpE3nysui7l%2Fimage.png?alt=media&#x26;token=13b506ad-a8a6-4f95-8ffd-7a7985299ccb" alt=""><figcaption></figcaption></figure>

12. Certificate created! Now locate and **Copy** the **SHA-1** at the end of the file

<div align="left"><figure><img src="https://4090346021-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FOQCKadC4SNL7ML9xwPi2%2Fuploads%2FuyKt211JOqbF9RtXeIDn%2Fimage.png?alt=media&#x26;token=e00289cf-905e-4a76-8103-d989b9a00bd0" alt=""><figcaption></figcaption></figure></div>

13. In the [***Mac\_AppGenerator***](#user-content-fn-1)[^1] folder open [**main.py**](#user-content-fn-2)[^2] with a text editor\
    Paste the **SHA-1** in the **SIGNING\_IDENTITY**  *(Remove the spaces)* and **Save the file**

<figure><img src="https://4090346021-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FOQCKadC4SNL7ML9xwPi2%2Fuploads%2FG598ZIAFoVRW3Am8S9v2%2Fimage.png?alt=media&#x26;token=f698234d-c15b-40c4-b659-2d6c7e8ab1a8" alt=""><figcaption><p>Paste the SHA-1 in the main.py (Remove the spaces)</p></figcaption></figure>

Proceed with the next step.

[^1]: This is located root of the GameLauncher-FlatWindow repository

[^2]: The script to generate the Mac App
