IQryptPFFile let you encrypt/decrypt PFFile with RND encryption scheme.

Creating a file

let str = "My data is my data, nobody should be able to exploit it!";
let data = str.dataUsingEncoding(NSUTF8StringEncoding);
let file = IQryptPFFile.getPFFile(name:"myfile.txt", data:data);
file.saveInBackground()

Assign the file to an IQryptPFObject

var obj= IQryptPFObject(className:"MyClass");
obj["myFile"] = file;
obj.saveInBackground();

*Notice that you don't have to set that the field "myFile" should be encrypted via IQryptConfigurator.encryptField(...) method, because the file was already IQryptPFFile instance.

Read the content back

let file = obj["myFile"] as PFFile;
let decryptedData = IQryptPFFile.getData(file);