the IP address of the sender is always stored in the original message i.e, the raw message. So if you are developing a function to get the original message then please also try to fetch the IP address of the sender if possible.
Thanks.
Thanks.