improve security in the integration code