![]() |
![]() |
|
|||||||
| Excel Questions All Excel/VBA questions - formulas, macros, pivot tables, general help, etc. Please post to this forum in English only. |
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
New Member
Join Date: Feb 2002
Posts: 11
|
Any ideas as to how I can do this? Either via VBA of some other means? Thanks!
|
|
|
|
|
|
#2 |
|
New Member
Join Date: Mar 2002
Posts: 34
|
um.... Hello, Mr. Gates. I know your a busy man with this anti trust suit, but could you set your priority team to work on my computer please?
I think the alternative to asking Mr. Gates for personal help would be to copy and paste the data to a new sheet. Good Luck -Dave |
|
|
|
|
|
#3 |
|
MrExcel MVP
Join Date: Mar 2002
Location: Chicago, IL USA
Posts: 2,042
|
Is this for the entire workbook, or sheet level? If this is for the entire workbook, you'll probably have to pay a fee to get it unlocked by some companies that can do it. I think Dave Hawley (a MrExcel regular) does it at OzGrid.
http://www.microsoftexceltraining.com/ If it is worksheet level, run the following code '---------------- Sub PasswordBreaker() 'by Bob McCormick on NG: microsoft.public.excel.misc 'on 22 May 2001. 'Breaks worksheet password protection. Dim i As Integer, j As Integer, k As Integer Dim l As Integer, m As Integer, n As Integer Dim i1 As Integer, i2 As Integer, i3 As Integer Dim i4 As Integer, i5 As Integer, i6 As Integer On Error Resume Next For i = 65 To 66 For j = 65 To 66 For k = 65 To 66 For l = 65 To 66 For m = 65 To 66 For i1 = 65 To 66 For i2 = 65 To 66 For i3 = 65 To 66 For i4 = 65 To 66 For i5 = 65 To 66 For i6 = 65 To 66 For n = 32 To 126 ActiveSheet.Unprotect Chr(i) & Chr(j) & Chr(k) & _ Chr(l) & Chr(m) & Chr(i1) & Chr(i2) & Chr(i3) _ & Chr(i4) & Chr(i5) & Chr(i6) & Chr(n) If ActiveSheet.ProtectContents = False Then MsgBox "One usable password is " & Chr(i) & Chr(j) _ & Chr(k) & Chr(l) & Chr(m) & Chr(i1) & Chr(i2) _ & Chr(i3) & Chr(i4) & Chr(i5) & Chr(i6) & Chr(n) Exit Sub End If Next Next Next Next Next Next Next Next Next Next Next Next End Sub '--------------------- Bye, Jay |
|
|
|
|
|
#4 |
|
MrExcel MVP
Join Date: Feb 2002
Location: Columbus, OH, USA
Posts: 3,519
|
Hey Jay,
I've used that sheet cracker code before. Do you know why it works? I have no clue. I know that Bob said it exploited a weakness in the security, but I'd be interested to see if there was anything I could read about it. |
|
|
|
|
|
#5 |
|
MrExcel MVP
Join Date: Mar 2002
Location: Chicago, IL USA
Posts: 2,042
|
Hi Mark,
I cannot find the original discussion I read regarding this. I know Eero Tibar posted a routine that does the same thing, only this was better, I believe. I think there was another routine, too, and the author was really shocked (he used the term 'pathetic' numerous times) to learn how easy it was to break the security. One of the responses in that post asked something like, "...my password is "MrExCel" and the code said "AAAAAAAEE" would open it, what gives?" The response was "any key that fits the lock can open it" or similar analogy, possibly even "the door was locked, so I tried the window." He gave some real details, but it was beyond me. I will try to find the discussion and post back. Bye, Jay |
|
|
|
|
|
#6 |
|
MrExcel MVP
Join Date: Feb 2002
Location: Central Florida, USA
Posts: 7,541
|
I may be wrong, but I think the code below works by finding the number of carry bits used to hold the password, setting each found carry bit and setting them as active in the code, then using simple substitution, finds the last character. It then code builds a working password based on the number of characters the original password has. The resulting password is composed of the number of carry bits contained in the original, the actual characters of which do not matter only the number of set carry bits, and the last character of the password, which may or may not be the actual caracter, only a character which does not set the last carry bit.
Sub PasswordBreaker() 'by Bob McCormick on NG microsoft.public.excel.misc on 22 May 2001. 'Breaks worksheet password protection. 'Note This code will not tell you what the password was (except by accident). 'What it does is exploit the poor encryption algorithm that is used for sheet password protection. Dim i As Integer, j As Integer, k As Integer Dim l As Integer, m As Integer, n As Integer Dim i1 As Integer, i2 As Integer, i3 As Integer Dim i4 As Integer, i5 As Integer, i6 As Integer On Error Resume Next For i = 65 To 66 For j = 65 To 66 For k = 65 To 66 For l = 65 To 66 For m = 65 To 66 For i1 = 65 To 66 For i2 = 65 To 66 For i3 = 65 To 66 For i4 = 65 To 66 For i5 = 65 To 66 For i6 = 65 To 66 For n = 32 To 126 ActiveSheet.Unprotect Chr(i) & Chr(j) & Chr(k) & Chr(l) & Chr(m) & Chr(i1) & Chr(i2) & Chr(i3) & Chr(i4) & Chr(i5) & Chr(i6) & Chr(n) Application.StatusBar = Chr(i) & Chr(j) & Chr(k) & Chr(l) & Chr(m) & Chr(i1) & Chr(i2) & Chr(i3) & Chr(i4) & Chr(i5) & Chr(i6) & Chr(n) If ActiveSheet.ProtectContents = False Then MsgBox "One useable password is " & Chr(i) & Chr(j) & Chr(k) & Chr(l) & Chr(m) & Chr(i1) & Chr(i2) & Chr(i3) & Chr(i4) & Chr(i5) & Chr(i6) & Chr(n) Application.StatusBar = False Exit Sub End If Next n Next i6 Next i5 Next i4 Next i3 Next i2 Next i1 Next m Next l Next k Next j Next i Application.StatusBar = False End Sub |
|
|
|
|
|
#7 |
|
MrExcel MVP
Join Date: Feb 2002
Location: Columbus, OH, USA
Posts: 3,519
|
Thanks JSW. (I bet you haven't looked for Jet Set Willy yet)
So, basically, it's a brute force method to find the carry bits and all that other stuff. Is this necessarily a weakness in design or was it just an old, cheap way to protect a sheet without too much work on MS's behalf? I mean only talking a couple of minutes at most for using this code. Even if you made your password "ZZZZZZZZZZ". Is this a case of just enough protection to deter the majority of people? (Incidentally, when I used this code it was to look some of our accountants spreadsheets "hidden" columns, just to see how they cheated us out of project funds. |
|
|
|
|
|
#8 |
|
MrExcel MVP
Join Date: Feb 2002
Location: Central Florida, USA
Posts: 7,541
|
Mark,
The best I can tell you are right. It has more to do with how the memory was used for the password rather than the actual password. At work I cannot use the net for any thing not deemed pass-worthy by the "Smart Filter" attached to our firewall. At home I have so little time that I have not had fee time to seach yet. But, I will eventually. JSW |
|
|
|
|
|
#9 |
|
Legend
Join Date: Feb 2002
Location: Minneapolis, Mn, USA
Posts: 9,704
|
Joe, ever put your firewall to these series of tests:
http://www.space.net.au/~thomas/quickbrowse.html And if that doesn't work, here's a link of 5 mirror sites! http://anonbrowse.cjb.net/ ![]() _________________ Cheers, NateO [ This Message was edited by: NateO on 2002-04-26 14:55 ] |
|
|
|
|
|
#10 |
|
Board Regular
Join Date: Feb 2002
Posts: 3,064
|
o will say little but you dont nned passwords to open things like no key to open lock bent coat hanger will sometimes do.
Excel is like a colinder (full of wholes) so the math (i cant spell... Mark help me .... Ar Ar o e m af it call speak tem letters to get der word.. its means math so its a case of adding and finding the produceinger of the password but warn JACK might also except Mark this is as the code is converted into gobbledoog thats the arrow.. bit i cant spells. its change the data so sometimes PW like ^^6gaf84j8974 2 are cracked by 3856h8464j4888 if you get me. but Jack will reproduce Jack... but simerly Mark can be a suggestion to the PW.. kinda like any key wont open door but this one will, its so close twist it shake it OPEN. 16 bit is simple nowas day,128 dual encryption on random arramathatical is reqd @strong box@ PW do you make sence of that... so the code attacks the PW by holding the sections of PW in a way that allows capture of the charcter, what else can it be a character be shape or number all are same ie can be replicated, so way a signature is unique but not random Chris D will love this no such fink as random i say as you can predict it or it possible to predict not that you can dead spot it but so the passord stutters and gives up letter by letter so its never secure. the trick is to allow part crack theis is what this code does.. ,.... help any.... i wont get into the techi stuff or tricky stuff, as dont fink your be intrested...
__________________
Free Excel based Web Toolbar available here. Jack in the UK J & R Excel Solutions "making Excel work for you" |
|
|
|
![]() |
| Bookmarks |
| Thread Tools | |
| Display Modes | |
|
|