SAS代码的密码保护

发布于 2024-07-26 03:15:08 字数 204 浏览 1 评论 0原文

有没有办法在 SAS 中使用密码保护 SAS CODE? 或者,如果没有,应用某种密码保护的最简单/最快的方法是什么?

我指的是从本地 Windows PC 运行的脚本(即不是批处理)。 脚本存储在标准网络驱动器上...

(理想情况下,解决方案不涉及 Microsoft 产品,例如 Word 或 Excel!!)

Is there a way to password protect SAS CODE within SAS? Or, if not, what is the easiest / quickest way to apply some kind of password protection?

I am referring to scripts run from local Windows PCs (ie not batch). The scripts are stored on a standard network drive...

(Ideally the solution would not involve a Microsoft product such as Word or Excel!!)

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

仙女山的月亮 2024-08-02 03:15:08

您可以尝试使用通过 NOSOURCE 和 NOEDIT 选项复制的 SCL 代码。
当然,这种方法依赖于您安装了 SAS/AF。

像这样:

  1. 创建一个新的本地 SCL 条目。 您的 INIT 部分要求输入或检查密码。 如果密码正确,则使用 LINK 命令将控制权交给另一个标签,如果不正确,则执行其他操作。
  2. 将您的 SAS 代码放入您在步骤 1 中链接到的标签中,如果它是 BASE SAS,请将其放入提交块中,在这种情况下,您还需要设置 NOSOURCE 和 NOSOURCE2 选项以防止您的程序显示在SAS 日志。
  3. 编译、保存并关闭您的 SCL 条目。
  4. 使用带有 NOSOURCE 和 NOEDIT 选项的 PROC COPY 将 SCL 复制到其最终目的地。

用户现在可以启动调用 SCL 的 SAS 会话。 如果提供正确的密码,SCL 代码将运行嵌入式 SAS 代码。 由于 NOSOURCE 选项,用户无法窥探密码,也无法从程序中窥探程序代码要点。

请注意,这不是最先进的高安全性密码保护!

这是一种快速但肮脏的方法,可防止“错误”的人运行特定的隐藏 SAS 代码。

You could try using SCL code copied with the NOSOURCE and NOEDIT options.
This approach of course relies on you having SAS/AF installed.

Like this:

  1. Create a new local SCL Entry. Your INIT section asks for or checks a password. If the password is correct, control is handed to another label with the LINK command, if not, do something else.
  2. Put your SAS code in the label you linked to in step 1, if it's BASE SAS, put it in a submit block, in which case you'll also want to set the NOSOURCE and NOSOURCE2 options to prevent your program to show up in the SAS log.
  3. Compile, save and close your SCL entry.
  4. Copy your SCL to its final destination using PROC COPY with the NOSOURCE and NOEDIT options.

Users can now start a SAS session that calls the SCL. If the correct password is provided, the SCL code runs the embedded SAS code. Users can't snoop the password, nor the program code essentials from the program due to the NOSOURCE option.

Note that this is not state of the art, high security password protection!

It's a quick and dirty way to keep the "wrong" people from running a specific piece of hidden SAS code.

挽容 2024-08-02 03:15:08

我认为你的问题的答案是“不”。

SAS对此没有很好的解决方案。 Windows对此没有很好的解决方案。

用于密码保护的第三方软件可能是您唯一的选择。

I think the answer to your question is "no".

SAS doesn't have a good solution for this. Windows doesn't have a good solution for this.

3rd party software for password protection may be your only option.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文