Thanks for your answer.
My case study is simple. I'm using IPFS to store and to retrieve some documents. The hash is stored in an Ethereum smart contract. At this stage, no issue as everything works perfectly.
But I'm wondering if there is an easy way to encrypt some files before saving them on IPFS (for example, files containing medical data). And of course, to decrypt these files when they are retrieved from IPFS.
So, how to easily mix encrypt and decrypt calls with ipfs.add and ipfs.get or ipfs.cat.