AWS Security ChangesHomeSearch

AWS msk documentation change

Service: msk · 2025-06-28 · Documentation low

File: msk/latest/developerguide/produce-consume.md

Summary

Replaced hardcoded paths/bootstrap strings with environment variables and added guidance to re-set variables in new sessions

Security assessment

The changes improve documentation clarity by using environment variables rather than hardcoded values, but this is a general usability improvement rather than a security-specific update. No evidence of addressing vulnerabilities or adding security controls.

Diff

diff --git a/msk/latest/developerguide/produce-consume.md b/msk/latest/developerguide/produce-consume.md
index 9e414d288..27e413b70 100644
--- a//msk/latest/developerguide/produce-consume.md
+++ b//msk/latest/developerguide/produce-consume.md
@@ -11 +11 @@ In this step of [Get Started Using Amazon MSK](./getting-started.html), you prod
-  1. Run the following command to start a console producer. Replace `BootstrapServerString` with the plaintext connection string that you obtained in [Create a topic](./create-topic.html). For instructions on how to retrieve this connection string, see [Getting the bootstrap brokers for an Amazon MSK cluster](./msk-get-bootstrap-brokers.html).
+  1. Run the following command to start a console producer.
@@ -13 +13 @@ In this step of [Get Started Using Amazon MSK](./getting-started.html), you prod
-        <path-to-your-kafka-installation>/bin/kafka-console-producer.sh --broker-list BootstrapServerString --producer.config <path-to-config>/client.properties --topic MSKTutorialTopic
+        $KAFKA_ROOT/bin/kafka-console-producer.sh --broker-list $BOOTSTRAP_SERVER --producer.config $KAFKA_ROOT/config/client.properties --topic MSKTutorialTopic
@@ -17 +17 @@ In this step of [Get Started Using Amazon MSK](./getting-started.html), you prod
-  3. Keep the connection to the client machine open, and then open a second, separate connection to that machine in a new window.
+  3. Keep the connection to the client machine open, and then open a second, separate connection to that machine in a new window. Because this is a new session, set the `KAFKA_ROOT` and `BOOTSTRAP_SERVER` environment variables again. For information about how to set these environment variables, see [Creating a topic on the client machine](./create-topic.html#create-topic-client-machine).
@@ -19 +19 @@ In this step of [Get Started Using Amazon MSK](./getting-started.html), you prod
-  4. In the following command, replace `BootstrapServerString` with the plaintext connection string that you saved earlier. Then, to create a console consumer, run the following command with your second connection to the client machine.
+  4. Run the following command with your second connection string to the client machine to create a console consumer.
@@ -21 +21 @@ In this step of [Get Started Using Amazon MSK](./getting-started.html), you prod
-        <path-to-your-kafka-installation>/bin/kafka-console-consumer.sh --bootstrap-server BootstrapServerString --consumer.config <path-to-config>/client.properties --topic MSKTutorialTopic --from-beginning
+        $KAFKA_ROOT/bin/kafka-console-consumer.sh --bootstrap-server $BOOTSTRAP_SERVER --consumer.config $KAFKA_ROOT/config/client.properties --topic MSKTutorialTopic --from-beginning
@@ -23 +23 @@ In this step of [Get Started Using Amazon MSK](./getting-started.html), you prod
-You start seeing the messages you entered earlier when you used the console producer command.
+You should start seeing the messages you entered earlier when you used the console producer command.