0
0
Nginxdevops~10 mins

SSL certificate installation in Nginx - Interactive Code Practice

Choose your learning style9 modes available
Practice - 5 Tasks
Answer the questions below
1fill in blank
easy

Complete the code to specify the SSL certificate file path in the nginx configuration.

Nginx
ssl_certificate [1];
Drag options to blanks, or click blank then click option'
A/etc/nginx/ssl/server.crt
B/etc/nginx/ssl/server.key
C/etc/nginx/ssl/ca_bundle.crt
D/etc/nginx/ssl/dhparam.pem
Attempts:
3 left
💡 Hint
Common Mistakes
Using the private key file path instead of the certificate file path.
Using the CA bundle file path in place of the certificate file.
2fill in blank
medium

Complete the code to specify the SSL certificate key file path in the nginx configuration.

Nginx
ssl_certificate_key [1];
Drag options to blanks, or click blank then click option'
A/etc/nginx/ssl/dhparam.pem
B/etc/nginx/ssl/ca_bundle.crt
C/etc/nginx/ssl/server.crt
D/etc/nginx/ssl/server.key
Attempts:
3 left
💡 Hint
Common Mistakes
Using the certificate file path instead of the private key file path.
Using the CA bundle or DH parameters file path here.
3fill in blank
hard

Fix the error in the nginx SSL configuration line to enable SSL on port 443.

Nginx
listen 443 [1];
Drag options to blanks, or click blank then click option'
Ahttp
Bssl
Chttps
Dtcp
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'http' or 'https' instead of 'ssl' in the listen directive.
Omitting the 'ssl' keyword, causing SSL not to work.
4fill in blank
hard

Fill both blanks to complete the nginx SSL configuration for the certificate and key files.

Nginx
ssl_certificate [1];
ssl_certificate_key [2];
Drag options to blanks, or click blank then click option'
A/etc/nginx/ssl/mydomain.crt
B/etc/nginx/ssl/mydomain.key
C/etc/nginx/ssl/server.key
D/etc/nginx/ssl/server.crt
Attempts:
3 left
💡 Hint
Common Mistakes
Swapping the certificate and key file paths.
Using default server files instead of your domain's files.
5fill in blank
hard

Fill all three blanks to complete the nginx SSL server block snippet with listen, certificate, and key directives.

Nginx
server {
    listen 443 [1];
    ssl_certificate [2];
    ssl_certificate_key [3];
}
Drag options to blanks, or click blank then click option'
Assl
B/etc/nginx/ssl/example.com.crt
C/etc/nginx/ssl/example.com.key
Dhttp
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'http' instead of 'ssl' in the listen directive.
Mixing up certificate and key file paths.