Hi EVERYONE
I want to protect my sas code with password. So no one can open sas code without password.
I know we can protect sas dataset with password. But i am not sure how can i add password to my sas program.
Thanks,
You should confirm with your company if the practice is allowed. In some cases that action could result in disciplinary actions because the company owns your work.
its allowed in company! i want to save my sas program with password protection in folder.
Thanks,
You'll need to use OS tools. I'm curious as to why this is needed? Is it to maintain a 'source of truth' or backups? If so, this is definitely not the best approach.
@sam1231 wrote:
its allowed in company! i want to save my sas program with password protection in folder.
Thanks,
there are better ways to do what you are asking. Talk to you Admin have them setup a specific location that only allows authorized users access. That is their job not yours. What happens if you die and the company needs to run the process???? I would hate to have to follow behind that practice.
The only way I know of doing this using SAS is to store your SAS program as a SOURCE entry in a SAS catalog then you can password-protect that.
What type of protection do you have in mind? If it is simply to stop others changing your software then using a version-control tool is a much better option.
Hi saskiwi,
i want to save my sas program in folder with password protection. so if anyone one to open it they need password to read/write sas program
I hope it helps to clear my question.
Thanks
>i want to save my sas program in folder with password protection
You can use a ZIP file then.
i want to save my sas program in folder with password protection. so if anyone one to open it they need password to read/write sas program
Why don't you just use operating system security? Either Windows or *nix makes this trivial to configure.
so if anyone one to open it they need password
Does it matter when someone shares the password with others?
Another option is compiled macros. Users could execute your macros, but would not be able to alter them. With proper options within the macro they won't even be able to see the code in the log. Hit the doc for details.
The use cases to read protect SAS code via a password and not just on OS folder level are rather rare. That's why you get so much "resistance".
What would help: Share with us your use case. Explain WHY you want to protect the source code this way. May be there are other/"better" ways with less negative impact to achieve what you need.
It would help us give you the best answer if you explained why you want to password-protect your SAS programs. You have clearly explained what you want, but not why.
the basic who, what, when, where, why questions that need to be answered to preformed and supply the final product.
SAS Innovate 2025 is scheduled for May 6-9 in Orlando, FL. Sign up to be first to learn about the agenda and registration!
Learn how use the CAT functions in SAS to join values from multiple variables into a single value.
Find more tutorials on the SAS Users YouTube channel.
Ready to level-up your skills? Choose your own adventure.