Check PST Password Protection
Contents
[
Hide
]
Aspose.Email - Check PST Password Protection
Microsoft Outlook lets users password protect PST files to restrict access to them. Aspose.Email can detect password protection on a PST file. This page shows how to check a PST for a password and also how to check if the password applied on it is correct.
Java
if (pst.getMessageStoreProperties().contains(MapiPropertyTag.PR_PST_PASSWORD))
{
long passwordHash = pst.getMessageStoreProperties().get_Item(MapiPropertyTag.PR_PST_PASSWORD).getLong();
return passwordHash != 0;
}
Download Running Code
Download Sample Code
For more details, visit Working with PST Password Protection Properties.