Microsoft Azure Portal already gives a capability to receive an email alert when new Azure Network Security Group  (NSG) is added or existing is deleted. However there is no option today to receive an email when individual NSG security rules are added, deleted or modified. This script will provide the solution to receive emails on Azure NSG security rules changes which isn’t offered by Azure Portal.

Refer to complete blog post for better understanding - http://sanganakauthority.blogspot.in/2017/08/how-to-receive-email-on-azure-network.html