Secure communication gateway design for smart grid