Once the PDF file is encrypted using Aspose.Pdf for .NET, you need to provide the password to decrypt the PDF document when viewing the PDF file. Once the file is decrypted, the contents are displayed as they were originally present in PDF file. From your above requirement, do you need to prevent the searching of contents inside PDF document ? if so is the case, then I am afraid this feature is currently not supported.
However as a workaround, you may first convert the pages of PDF file into Image format and then again create a PDF file using those images. We are sorry for this inconvenience.