Posted On: Sep 28, 2023

Today, AWS IoT Core a fully managed cloud service that lets you connect billions of devices and process trillions of messages, announces a new inline Rule function that enables you to extract the source IP address of the publisher of an IoT message. Once you extract the source IP address, you can send it to other AWS and third-party services for further analytics based on your business needs. For example, you can use the source IP address with location solvers (such as, AWS IoT Core Device Location) to determine the approximate location of an IoT device and build location-based applications, such as asset tracking, video content delivery etc.

Rules Engine is a component of AWS IoT Core that allows you to filter, transform, and process IoT device data and route the data to 15+ AWS and third party services. The new inline function in Rules Engine supports both IPv4 and IPv6 addresses, giving you flexibility to capture the source IP address information, irrespective of the address type. To get started, connect your IoT devices to AWS IoT Core, and call the sourceip() inline function to retrieve the source IP address of the IoT message.  

AWS IoT Core’s capability to retrieve the source IP is available in the following AWS Regions: US East (N. Virginia), US East (Ohio), US West (N. California), US West (Oregon), Asia Pacific (Hong Kong), Asia Pacific (Mumbai), Asia Pacific (Seoul), Asia Pacific (Singapore), Asia Pacific (Sydney), Asia Pacific (Tokyo), Canada (Central), Europe (Frankfurt), Europe (Ireland), Europe (London), Europe (Paris), Europe (Stockholm), Middle East (Bahrain), Middle East (UAE), South America (Sao Paulo), AWS GovCloud (US-East), and AWS GovCloud (US-West). 

For more information, refer to the developer guide