Ancient magicians used a number of different encryption methods to protect their written knowledge from the eyes of unauthorized persons. Next to a completely encrypted magical papyrus from the 2nd century, the key to several ciphers has been preserved in a little later Egyptian papyrus. The code itself has not been used in the papyrus, and we do not know of any text in which the key was applied. This is simply because no one has yet conducted a systematic research.
Secrecy and encryption were also particularly popular for individual ritual ingredients. Either by writing them in a secret script or by giving them code names.
Secret writing is the subject of the next episode: Daily Ancient Magic: Code words for Ritual Ingredients.