Using connect to add a security layer