0
0
Nginxdevops~10 mins

Why HTTPS secures communication in Nginx - Test Your Understanding

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

Complete the code to enable HTTPS by specifying the SSL certificate file.

Nginx
ssl_certificate [1];
Drag options to blanks, or click blank then click option'
A/etc/nginx/ssl/server.crt
B/etc/nginx/conf.d/default.conf
C/var/www/html/index.html
D/etc/nginx/nginx.conf
Attempts:
3 left
💡 Hint
Common Mistakes
Using configuration files or HTML files instead of certificate files.
2fill in blank
medium

Complete the code to specify the SSL key file for HTTPS in nginx configuration.

Nginx
ssl_certificate_key [1];
Drag options to blanks, or click blank then click option'
A/usr/share/nginx/html/index.html
B/etc/nginx/conf.d/ssl.conf
C/etc/nginx/ssl/server.key
D/var/log/nginx/access.log
Attempts:
3 left
💡 Hint
Common Mistakes
Using log files or HTML files instead of key files.
3fill in blank
hard

Fix the error in the nginx server block to listen on HTTPS port.

Nginx
listen [1] ssl;
Drag options to blanks, or click blank then click option'
A8080
B443
C80
D22
Attempts:
3 left
💡 Hint
Common Mistakes
Using port 80 or other ports which are not standard for HTTPS.
4fill in blank
hard

Fill both blanks to complete the nginx server block for HTTPS with strong security.

Nginx
ssl_protocols [1];
ssl_ciphers [2];
Drag options to blanks, or click blank then click option'
ATLSv1.2 TLSv1.3
BSSLv3 TLSv1
CHIGH:!aNULL:!MD5
DLOW:!SSLv3
Attempts:
3 left
💡 Hint
Common Mistakes
Using outdated protocols or weak cipher suites.
5fill in blank
hard

Fill all three blanks to configure nginx to redirect HTTP to HTTPS and enable SSL.

Nginx
server {
    listen [1];
    return [2] https://$host$request_uri;
}

server {
    listen [3] ssl;
    ssl_certificate /etc/nginx/ssl/server.crt;
    ssl_certificate_key /etc/nginx/ssl/server.key;
}
Drag options to blanks, or click blank then click option'
A80
B301
C443
D302
Attempts:
3 left
💡 Hint
Common Mistakes
Using wrong ports or temporary redirect codes.