Return-Path: X-Original-To: apmail-poi-user-archive@www.apache.org Delivered-To: apmail-poi-user-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 36E1B9B06 for ; Thu, 15 Mar 2012 16:16:47 +0000 (UTC) Received: (qmail 80251 invoked by uid 500); 15 Mar 2012 16:16:46 -0000 Delivered-To: apmail-poi-user-archive@poi.apache.org Received: (qmail 80225 invoked by uid 500); 15 Mar 2012 16:16:46 -0000 Mailing-List: contact user-help@poi.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "POI Users List" Delivered-To: mailing list user@poi.apache.org Received: (qmail 80216 invoked by uid 99); 15 Mar 2012 16:16:46 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 15 Mar 2012 16:16:46 +0000 X-ASF-Spam-Status: No, hits=2.9 required=5.0 tests=HTML_MESSAGE,SPF_NEUTRAL X-Spam-Check-By: apache.org Received-SPF: neutral (athena.apache.org: local policy) Received: from [74.115.204.54] (HELO relay-hub202.domainlocalhost.com) (74.115.204.54) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 15 Mar 2012 16:16:40 +0000 Received: from MBX244.domain.local ([169.254.4.147]) by HUB202.domain.local ([192.168.69.2]) with mapi id 14.01.0355.002; Thu, 15 Mar 2012 12:16:19 -0400 From: Matt Rogghe To: POI Users List Subject: Excel 2007+ with password protection Thread-Topic: Excel 2007+ with password protection Thread-Index: Ac0CxvNJxph75p+FQqSukHoXajzjog== Date: Thu, 15 Mar 2012 16:16:18 +0000 Message-ID: <84FC8BBE1CE6B2458B946E61D3C5B29315BAB023@MBX244.domain.local> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [192.168.64.26] Content-Type: multipart/alternative; boundary="_000_84FC8BBE1CE6B2458B946E61D3C5B29315BAB023MBX244domainloc_" MIME-Version: 1.0 X-Virus-Checked: Checked by ClamAV on apache.org --_000_84FC8BBE1CE6B2458B946E61D3C5B29315BAB023MBX244domainloc_ Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable I've been experimenting with opening password protected (not encrypted) wor= kbooks. The HSSF (2003 and lower) versions seem to work fine when using th= e org.apache.poi.hssf.record.crypto.Biff8EncryptionKey methods. The XSSF m= ethods seem to be problematic. poi-3.8-beta5 Using the following methods to determine workbook version and get an object= to work with: POIFSFileSystem.hasPOIFSHeader(inputStream), POIXMLDocument.= hasOOXMLHeader(inputStream) as well as the generic WorkbookFactory.create(i= nputStream). When I come across a 2007+ workbook that has been saved as password protect= ed POI determines that the file is in HSSF/BIFF format. Error generated: The supplied POIFSFileSystem does not contain a BIFF8 'Workbook' entry. Is = it really an excel file? Has anyone had success opening password protected 2007+ files? Steps to reproduce: 1. Create a new Excel file using Excel 2007+. 2. Save As -> 3. Click Tools -> General Options 4. Enter a password in both or either fields. 5. OK and save. 6. Attempt to read the file using POI. --_000_84FC8BBE1CE6B2458B946E61D3C5B29315BAB023MBX244domainloc_--