Skip to content
Browse files

Moving “DHxlsReader” files from “DHxlsReaderIOS” to “DHxlsReader”.

  • Loading branch information...
1 parent 1247e87 commit 9706ff33b018495135aa9300562027ca3a14fe8c Jan Weiß committed Jul 20, 2013
View
0 DHxlsReaderIOS/DHcell-Private.h → DHxlsReader/DHcell-Private.h
File renamed without changes.
View
0 DHxlsReaderIOS/DHcell.h → DHxlsReader/DHcell.h
File renamed without changes.
View
0 DHxlsReaderIOS/DHcell.m → DHxlsReader/DHcell.m
File renamed without changes.
View
0 DHxlsReaderIOS/DHxlsReaderIOS.h → DHxlsReader/DHxlsReader.h
File renamed without changes.
View
2 DHxlsReaderIOS/DHxlsReaderIOS.m → DHxlsReader/DHxlsReader.m
@@ -29,7 +29,7 @@
*/
-#import "DHxlsReaderIOS.h"
+#import "DHxlsReader.h"
#import "DHcell-Private.h"
#import "xls.h"
View
32 DHxlsReaderIOS.xcodeproj/project.pbxproj
@@ -8,15 +8,15 @@
/* Begin PBXBuildFile section */
97BCBBE916DD4E9A00FF978C /* Cocoa.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 97BCBBE816DD4E9A00FF978C /* Cocoa.framework */; };
- 97BCBBF816DD4EBD00FF978C /* DHxlsReaderIOS.m in Sources */ = {isa = PBXBuildFile; fileRef = DEB78AC814BB9ABF00845894 /* DHxlsReaderIOS.m */; };
+ 97BCBBF816DD4EBD00FF978C /* DHxlsReader.m in Sources */ = {isa = PBXBuildFile; fileRef = DEB78AC814BB9ABF00845894 /* DHxlsReader.m */; };
97BCBBF916DD4EBD00FF978C /* DHcell.m in Sources */ = {isa = PBXBuildFile; fileRef = DEB78B4F14BBA42300845894 /* DHcell.m */; };
97BCBBFA16DD4EBD00FF978C /* ole.c in Sources */ = {isa = PBXBuildFile; fileRef = DEB78B1914BB9E6200845894 /* ole.c */; };
97BCBBFB16DD4EBD00FF978C /* xls.c in Sources */ = {isa = PBXBuildFile; fileRef = DEB78B1A14BB9E6200845894 /* xls.c */; };
97BCBBFC16DD4EBD00FF978C /* xlstool.c in Sources */ = {isa = PBXBuildFile; fileRef = DEB78B1C14BB9E6200845894 /* xlstool.c */; };
DE2A39661502846600E4AF15 /* config.h in Headers */ = {isa = PBXBuildFile; fileRef = DE2A39651502846600E4AF15 /* config.h */; };
DE9798CA14BC839E006E5AC2 /* libiconv.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = DE9798C914BC839E006E5AC2 /* libiconv.dylib */; };
DEB78AC314BB9ABF00845894 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = DEB78AC214BB9ABF00845894 /* Foundation.framework */; };
- DEB78AC914BB9ABF00845894 /* DHxlsReaderIOS.m in Sources */ = {isa = PBXBuildFile; fileRef = DEB78AC814BB9ABF00845894 /* DHxlsReaderIOS.m */; };
+ DEB78AC914BB9ABF00845894 /* DHxlsReader.m in Sources */ = {isa = PBXBuildFile; fileRef = DEB78AC814BB9ABF00845894 /* DHxlsReader.m */; };
DEB78B3114BB9E6200845894 /* brdb.c.h in Headers */ = {isa = PBXBuildFile; fileRef = DEB78AEF14BB9E6200845894 /* brdb.c.h */; };
DEB78B3214BB9E6200845894 /* brdb.h in Headers */ = {isa = PBXBuildFile; fileRef = DEB78AF014BB9E6200845894 /* brdb.h */; };
DEB78B3414BB9E6200845894 /* ole.h in Headers */ = {isa = PBXBuildFile; fileRef = DEB78AF414BB9E6200845894 /* ole.h */; };
@@ -44,8 +44,8 @@
DEB78ABF14BB9ABF00845894 /* libDHxlsReaderIOS.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libDHxlsReaderIOS.a; sourceTree = BUILT_PRODUCTS_DIR; };
DEB78AC214BB9ABF00845894 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; };
DEB78AC614BB9ABF00845894 /* DHxlsReaderIOS-Prefix.pch */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "DHxlsReaderIOS-Prefix.pch"; sourceTree = "<group>"; };
- DEB78AC714BB9ABF00845894 /* DHxlsReaderIOS.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = DHxlsReaderIOS.h; sourceTree = "<group>"; };
- DEB78AC814BB9ABF00845894 /* DHxlsReaderIOS.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = DHxlsReaderIOS.m; sourceTree = "<group>"; };
+ DEB78AC714BB9ABF00845894 /* DHxlsReader.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = DHxlsReader.h; sourceTree = "<group>"; };
+ DEB78AC814BB9ABF00845894 /* DHxlsReader.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = DHxlsReader.m; sourceTree = "<group>"; };
DEB78AE214BB9E6200845894 /* main.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = main.cpp; sourceTree = "<group>"; };
DEB78AE414BB9E6200845894 /* XlsReader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = XlsReader.cpp; sourceTree = "<group>"; };
DEB78AE514BB9E6200845894 /* XlsReader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XlsReader.h; sourceTree = "<group>"; };
@@ -99,6 +99,11 @@
97BCBBEE16DD4E9A00FF978C /* DHxlsReader */ = {
isa = PBXGroup;
children = (
+ DEB78AC714BB9ABF00845894 /* DHxlsReader.h */,
+ DEB78AC814BB9ABF00845894 /* DHxlsReader.m */,
+ DEB78B4E14BBA42300845894 /* DHcell.h */,
+ DEB78B4F14BBA42300845894 /* DHcell.m */,
+ DEB78B5214BBA58300845894 /* DHcell-Private.h */,
97BCBBEF16DD4E9A00FF978C /* Supporting Files */,
);
path = DHxlsReader;
@@ -117,10 +122,9 @@
children = (
DE2A39651502846600E4AF15 /* config.h */,
DEB78B6314BC72D000845894 /* README.md */,
- DEB78AC414BB9ABF00845894 /* DHxlsReaderIOS */,
+ 97BCBBEE16DD4E9A00FF978C /* DHxlsReader */,
DEB78ACF14BB9E6200845894 /* libxls */,
DEB78AC514BB9ABF00845894 /* Supporting Files */,
- 97BCBBEE16DD4E9A00FF978C /* DHxlsReader */,
DEB78AC114BB9ABF00845894 /* Frameworks */,
DEB78AC014BB9ABF00845894 /* Products */,
);
@@ -146,18 +150,6 @@
name = Frameworks;
sourceTree = "<group>";
};
- DEB78AC414BB9ABF00845894 /* DHxlsReaderIOS */ = {
- isa = PBXGroup;
- children = (
- DEB78AC714BB9ABF00845894 /* DHxlsReaderIOS.h */,
- DEB78AC814BB9ABF00845894 /* DHxlsReaderIOS.m */,
- DEB78B4E14BBA42300845894 /* DHcell.h */,
- DEB78B4F14BBA42300845894 /* DHcell.m */,
- DEB78B5214BBA58300845894 /* DHcell-Private.h */,
- );
- path = DHxlsReaderIOS;
- sourceTree = "<group>";
- };
DEB78AC514BB9ABF00845894 /* Supporting Files */ = {
isa = PBXGroup;
children = (
@@ -314,7 +306,7 @@
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
- 97BCBBF816DD4EBD00FF978C /* DHxlsReaderIOS.m in Sources */,
+ 97BCBBF816DD4EBD00FF978C /* DHxlsReader.m in Sources */,
97BCBBF916DD4EBD00FF978C /* DHcell.m in Sources */,
97BCBBFA16DD4EBD00FF978C /* ole.c in Sources */,
97BCBBFB16DD4EBD00FF978C /* xls.c in Sources */,
@@ -326,7 +318,7 @@
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
- DEB78AC914BB9ABF00845894 /* DHxlsReaderIOS.m in Sources */,
+ DEB78AC914BB9ABF00845894 /* DHxlsReader.m in Sources */,
DEB78B3D14BB9E6200845894 /* ole.c in Sources */,
DEB78B3E14BB9E6200845894 /* xls.c in Sources */,
DEB78B4014BB9E6200845894 /* xlstool.c in Sources */,
View
34 DHxlsReaderIOS/DHxlsReader.h
@@ -0,0 +1,34 @@
+/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
+ *
+ * This file is part of DHlibxls -- permitting code to read Excel(TM) files.
+ *
+ * Copyright 2012 David Hoerl All Rights Reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without modification, are
+ * permitted provided that the following conditions are met:
+ *
+ * 1. Redistributions of source code must retain the above copyright notice, this list of
+ * conditions and the following disclaimer.
+ *
+ * 2. Redistributions in binary form must reproduce the above copyright notice, this list
+ * of conditions and the following disclaimer in the documentation and/or other materials
+ * provided with the distribution.
+ *
+ * 3. Only the ObjectiveC code is under this license - separate license may apply to libxls source.
+ * Read the documents and source headers in the libxls files which you downloaded earlier.
+ *
+ * THIS SOFTWARE IS PROVIDED BY David Hoerl ''AS IS'' AND ANY EXPRESS OR IMPLIED
+ * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
+ * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL David Hoerl OR
+ * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
+ * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
+ * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
+ * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+
+#import "../DHxlsReader/DHxlsReader.h"
+
+#warning "This file is a shim. Please use ../DHxlsReader/DHxlsReader.h instead!"
View
6 TestDHlibxls.xcodeproj/project.pbxproj
@@ -302,7 +302,7 @@
GCC_WARN_ABOUT_MISSING_PROTOTYPES = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
- HEADER_SEARCH_PATHS = DHxlsReaderIOS;
+ HEADER_SEARCH_PATHS = DHxlsReader;
OTHER_CFLAGS = "-DNS_BLOCK_ASSERTIONS=1";
SDKROOT = iphoneos;
VALIDATE_PRODUCT = YES;
@@ -337,7 +337,7 @@
GCC_WARN_ABOUT_MISSING_PROTOTYPES = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
- HEADER_SEARCH_PATHS = DHxlsReaderIOS;
+ HEADER_SEARCH_PATHS = DHxlsReader;
SDKROOT = iphoneos;
};
name = Debug;
@@ -354,7 +354,7 @@
GCC_WARN_ABOUT_MISSING_PROTOTYPES = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
- HEADER_SEARCH_PATHS = DHxlsReaderIOS;
+ HEADER_SEARCH_PATHS = DHxlsReader;
OTHER_CFLAGS = "-DNS_BLOCK_ASSERTIONS=1";
SDKROOT = iphoneos;
VALIDATE_PRODUCT = YES;
View
2 TestDHlibxls/ViewController.m
@@ -8,7 +8,7 @@
#import "ViewController.h"
-#import "DHxlsReaderIOS.h"
+#import "DHxlsReader.h"
extern int xls_debug;

6 comments on commit 9706ff3

@yunusm7

Hi,
How can i read password protected xls file using DHxlsReaderIOS reader.
Thanks in advance

@dhoerl
Owner
dhoerl commented on 9706ff3 Feb 25, 2014

If it does not work now, I will guess its not possible. Probably Excel has encrypted the data, and in the program, after you provide a password, it unencrypts the data, then parsers it.

That said, there are a slew of other Excel file readers in various languages (PHP, etc). If you google around, and find a solution, I'd be glad to add it to the program. Perhaps someone else has figured out the unencryption algorithm.

In any case you will surely need the password. But, I vaguely recall seening password crackers advertised that will brute force an Excel file - I was reading up about it - hmmm let me look. Well, I could not find the reference, but I did get a slew of responses googling "how to crack Excel passwords".

@JanX2
JanX2 commented on 9706ff3 Feb 25, 2014

I have read that there commercial apps that do that even without the password, but the sources alas are not available. ;)

@yunusm7

@dhoerl: I dont need to crack excel password because i have the password. Is there any way to pass the password with xls sheet name and get data.

@dhoerl
Owner
dhoerl commented on 9706ff3 Feb 25, 2014

No. That was my point. Even with the proper password, there is no known way to apply it. If you can find what needs to be done - for instance use the password to unencrypted the bulk of the file - then possibly we could do something. As it stands, the file format does not tell us WHAT do to to unencrypted the data. I'll take another look, but pretty sure nothing is provided by MS.

@dhoerl
Owner
dhoerl commented on 9706ff3 Feb 26, 2014

OK - I looked deeper. It does seem like there is a way to unencrypted the data - its in the OpenOffice guide section 4.19 File Protection. While not all that complex, its going to require some code restructuring and so is not trivial. I probably can get to it in the next month or so, but cannot spin such a big feature in an hour. Please let me know via a comment here whether having it in the future is worthwhile or not for you. Do not want to code it for no reason.

Please sign in to comment.
Something went wrong with that request. Please try again.