Analysis of Cryptographic Protocols: the Environment and the Application