Solved

Securing Excel Sheet.

Posted on 2004-10-16
5
258 Views
Last Modified: 2010-08-05
Hi All,

This is related to Visual Basic Application (excel)
My question is :
I have a new excel sheet open and if we press ALT+F11 from Excel Sheet, it will open the Visual Basic Application or code window.
What should I do to secure my code?, like entering a user name and password before it opens the VB code window.

Also, I heard some one saying even though if you secure (asking for U.nane and PWD before entering to the VBA or VB code), it is very easy to break in to code. Is it true?

Please help me out to secure excel sheet.


Thanks
Have a good day
0
Comment
Question by:Tpaul_10
5 Comments
 
LVL 85

Assisted Solution

by:Mike Tomlinson
Mike Tomlinson earned 150 total points
ID: 12328713
This PAQ explains how to do it:
http://www.experts-exchange.com/Applications/MS_Office/Q_10293525.html

I don't know how secure or easy it is to break this security feature though.

~IM
0
 
LVL 80

Assisted Solution

by:byundt
byundt earned 150 total points
ID: 12330904
If you do a Google search for Excel VBA password crack, you will find a number of sources for commercial products that purport to break the password protecting a VBA project. It's harder to crack than the password protection for worksheets, but still relatively inexpensive in terms of time and money.

Compiled VB code will be more secure (as an add-in) than VBA.

If you stick with VBA, you should consider obfuscating your code. This involves:
1) Multiple instructions on each line of code, with no "structuring" for readability
2) Variable names should be as similar as possible--random combinations of letters and numbers are excellent choices
3) Include extra instructions that don't actually do anything--but look as though they are
4) Don't comment anything
0
 
LVL 3

Accepted Solution

by:
Fairco earned 200 total points
ID: 12332995
VBA password is one of the easiest to recover, since there's a built-in backdoor in Excel that enables bypassing of the password. Like byundt said, several commercial applications exist for activating the bypass method.

If you really want to protect your code, you should consider using the DRM-like document security system implemented in Excel 2003. Only users selected by the author can view (or modify) the workbook, and it requires .NET passport authentication from everyone acessing it. The security uses a more complex encryption to the whole document, therefore it can't be simply bypassed. Kinda strong stuff and well designed. I recommend taking a look at it. One drawback is that only Excel 2003 can fully decrypt the document, therefore everyone accessing it must have Excel 2003. You can set Excel 2000 compatibility for viewing, but that's really weak.
0
 

Author Comment

by:Tpaul_10
ID: 12667331
Thanks to all of you Guys.
All of your feedback and information is very usefull.

Thanks
Have a great day
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

When designing a form there are several BorderStyles to choose from, all of which can be classified as either 'Fixed' or 'Sizable' and I'd guess that 'Fixed Single' or one of the other fixed types is the most popular choice. I assume it's the most p…
Since upgrading to Office 2013 or higher installing the Smart Indenter addin will fail. This article will explain how to install it so it will work regardless of the Office version installed.
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…

746 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now