Skip to content

Commit

Permalink
added readme for creaeting using rsa keys
Browse files Browse the repository at this point in the history
  • Loading branch information
Awhiteweb committed Feb 9, 2023
1 parent c04f31c commit 1db7055
Show file tree
Hide file tree
Showing 14 changed files with 63 additions and 0 deletions.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
63 changes: 63 additions & 0 deletions README_Binance_RSA_Keys.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
# Using RSA keys with Binance

Binance now supports the use of RSA encryption keys with their API. To use RSA keys instead of the previous HMAC keys generated by Binance please follow along.

After signing into Binance navigate to the API management area

![User drop down](./Projects/Foundations/PNGs/Docs/rsa-keys/binance/binance-create-rsa-key-01.png)

Here you can create an new Key

![Create a new key](./Projects/Foundations/PNGs/Docs/rsa-keys/binance/binance-create-rsa-key-02.png)

This will open a new dialog modal where you need to select the 'Self-generated' option.

![Select seff-generated](./Projects/Foundations/PNGs/Docs/rsa-keys/binance/binance-create-rsa-key-03.png)

This will open a new dialog asking you to input the public key. Binance uses a PKCS#8 private key and an X509 public key. If you are not sure what this all means then go the link binance provide, download the key generator tool and follow the next steps.

## Generating a new key pair

Open the key generation tool and select the 2048 bit enxryption option. *The 4096 keys will not be accepted by Binance.*

![Generate a 2048 key part 1](./Projects/Foundations/PNGs/Docs/rsa-keys/binance/binance-create-rsa-key-04.png)

Click the 'Generate Key Pair' button. This will create 2 new keys in the input boxes below.

![Generate a 2048 key part 2](./Projects/Foundations/PNGs/Docs/rsa-keys/binance/binance-create-rsa-key-05.png)

These keys can now be saved to your trading server.

Our advise is to put these in the **My-Secrets** folder of your Superalgos directory, but you may stored them where-ever you like.

![Save public key](./Projects/Foundations/PNGs/Docs/rsa-keys/binance/binance-create-rsa-key-06.png)

![Save private key](./Projects/Foundations/PNGs/Docs/rsa-keys/binance/binance-create-rsa-key-07.png)

## Using your keys

Now that these have been stored you need to open the public key and copy the contents.

![Copy public key data](./Projects/Foundations/PNGs/Docs/rsa-keys/binance/binance-create-rsa-key-08.png)

Paste the public key contents into the Binance 'Upload public key' dialog modal, and click next.

![Paste public key data](./Projects/Foundations/PNGs/Docs/rsa-keys/binance/binance-create-rsa-key-09.png)

Provide a suitable name for your key.

![Name key in binance](./Projects/Foundations/PNGs/Docs/rsa-keys/binance/binance-create-rsa-key-10.png)

You will now be directed back the API management page where you can view a list of your keys. You will need to edit the restrictions on your new key to 'Enable Spot & Margin Trading'.

![Set key permissions](./Projects/Foundations/PNGs/Docs/rsa-keys/binance/binance-create-rsa-key-11.png)

Now copy the API key hash Binance provides.

![Copy key hash](./Projects/Foundations/PNGs/Docs/rsa-keys/binance/binance-create-rsa-key-12.png)

And paste this into the Exchange account key node's config as the **codeName** value. Then set the path to the provate key as the **secret** value.

![Save details to Superalgos](./Projects/Foundations/PNGs/Docs/rsa-keys/binance/binance-create-rsa-key-13.png)

*It is import to note that the private key needs to be stored on the same server that the tasks run on and the path to the file must be valid. The path value can be either relative or absolute*

0 comments on commit 1db7055

Please sign in to comment.