Version 18.1 by Erik Bakker on 2022/06/10 08:38

Show last authors
1 {{container}}{{container layoutStyle="columns"}}(((
2 = SFTP Security =
3
4 In the last microlearning, we discussed how to connect to an SFTP from eMagiz. In this microlearning, we want to expand our knowledge and look at a more complex security configuration when connecting to SFTP instances. The configuration we are talking about is the private key configuration.
5
6 Should you have any questions, please get in touch with [[academy@emagiz.com>>mailto:academy@emagiz.com]].
7
8 * Last update: August 25th, 2021
9 * Required reading time: 9 minutes
10
11 == 1. Prerequisites ==
12
13 * Basic knowledge of the eMagiz platform
14 * Novice course on File-based connectivity
15
16 == 2. Key concepts ==
17
18 This microlearning is about SFTP security.
19
20 By SFTP security, we mean: Making sure that the SFTP we connect to knows that we are indeed eMagiz
21
22 * Private key is unique per client
23 * Private key should only be known to the client
24 * Public key should be known to the SFTP (server), so they trust us when we set up the communication
25 * A private key comes with a passphrase
26
27
28
29 == 3. SFTP Security ==
30
31 In the last microlearning, we discussed how to connect to an SFTP from eMagiz. In this microlearning, we want to expand our knowledge and look at a more complex security configuration when connecting to SFTP instances. The configuration we are talking about is the private key configuration.
32
33 * Private key is unique per client
34 * Private key should only be known to the client
35 * Public key should be known to the SFTP (server), so they trust us when we set up the communication
36 * A private key comes with a passphrase
37
38 If you are looking for some introductory reading into certificates, please check this [microlearning](novice-securing-your-data-traffic-what-are-certificates.md).
39
40 As the private key is yours, you can ask a trusted party to generate the key, or you could create it yourself. The latter part happens a lot when connecting to an SFTP. You could use a tool like PuttyGen to achieve this. As a result, you will have a keypair. The private key should be kept safely with you in eMagiz, and you need to share the public key with the SFTP server party. In this microlearning, I will not explain how PuttyGen works in detail. Instead, we will focus on the part in eMagiz. In eMagiz, we need to refer to the key file (linked under Resources), and we need to refer to the password we use to save our key file securely.
41
42 [[image:Main.Images.Microlearning.WebHome@intermediate-file-based-connectivity-sftp-security--private-key-config.png]]
43
44 Note that the use of a password and a private key are mutually exclusive. So you need to either provide a password or a private key for authentication. In the help text provided by eMagiz, you can see how the reference to the key file should be made.
45
46 When you have configured these settings, you have finished the configuration in eMagiz. Now you could test whether the configuration is set up correctly between eMagiz and the SFTP. If this is not the case, eMagiz will notify you via the Manage phase, either as an error message or a log entry.
47
48 Using this setting gives the server the option to verify if the communication request came from eMagiz (or at least from the party that holds the private key of eMagiz). This is an additional security measure to ensure data integrity and quality.
49
50
51
52 == 4. Assignment ==
53
54 Check within your project(s) whether an SFTP connection is secured with the help of private key construction.
55 This assignment can be completed with the help of the (Academy) project that you have created/used in the previous assignment.
56
57 == 5. Key takeaways ==
58
59 * Private key is unique per client
60 * Private key should only be known to the client
61 * Public key should be known to the SFTP (server), so they trust us when we set up the communication
62 * A private key comes with a passphrase
63
64
65
66 == 6. Suggested Additional Readings ==
67
68 If you are interested in this topic and want more information, please read the release notes provided by eMagiz. Furthermore, check out these links:
69
70 * https://docs.spring.io/spring-integration/docs/2.2.6.RELEASE/reference/html/sftp.html#sftp-outbound
71 * https://docs.spring.io/spring-integration/docs/2.2.6.RELEASE/reference/html/sftp.html#sftp-session-factory
72 * https://www.2brightsparks.com/resources/articles/sftp-authentication.html
73
74 == 7. Silent demonstration video ==
75
76 As this is a more theoretical microlearning, there is no video.
77
78 )))((({{toc/}}))){{/container}}{{/container}}