• <i id='Ld4Fh'><tr id='Ld4Fh'><dt id='Ld4Fh'><q id='Ld4Fh'><span id='Ld4Fh'><b id='Ld4Fh'><form id='Ld4Fh'><ins id='Ld4Fh'></ins><ul id='Ld4Fh'></ul><sub id='Ld4Fh'></sub></form><legend id='Ld4Fh'></legend><bdo id='Ld4Fh'><pre id='Ld4Fh'><center id='Ld4Fh'></center></pre></bdo></b><th id='Ld4Fh'></th></span></q></dt></tr></i><div id='Ld4Fh'><tfoot id='Ld4Fh'></tfoot><dl id='Ld4Fh'><fieldset id='Ld4Fh'></fieldset></dl></div>
      <tfoot id='Ld4Fh'></tfoot>

      <small id='Ld4Fh'></small><noframes id='Ld4Fh'>

      1. <legend id='Ld4Fh'><style id='Ld4Fh'><dir id='Ld4Fh'><q id='Ld4Fh'></q></dir></style></legend>
          <bdo id='Ld4Fh'></bdo><ul id='Ld4Fh'></ul>
      2. PHP &amp;cron:安全问题

        时间:2023-08-17
            <bdo id='zC2z4'></bdo><ul id='zC2z4'></ul>
              <tbody id='zC2z4'></tbody>
          • <tfoot id='zC2z4'></tfoot>

                <i id='zC2z4'><tr id='zC2z4'><dt id='zC2z4'><q id='zC2z4'><span id='zC2z4'><b id='zC2z4'><form id='zC2z4'><ins id='zC2z4'></ins><ul id='zC2z4'></ul><sub id='zC2z4'></sub></form><legend id='zC2z4'></legend><bdo id='zC2z4'><pre id='zC2z4'><center id='zC2z4'></center></pre></bdo></b><th id='zC2z4'></th></span></q></dt></tr></i><div id='zC2z4'><tfoot id='zC2z4'></tfoot><dl id='zC2z4'><fieldset id='zC2z4'></fieldset></dl></div>

                <legend id='zC2z4'><style id='zC2z4'><dir id='zC2z4'><q id='zC2z4'></q></dir></style></legend>

                  <small id='zC2z4'></small><noframes id='zC2z4'>

                • 本文介绍了PHP &amp;cron:安全问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

                  问题描述

                  确保只有 CRON 执行 PHP 脚本的最佳方法是什么,而不是其他人偶然发现您的 php 脚本..

                  Whats the best way to ensure that only CRON executes PHP scripts, and not someone else who stumbled upon your php scripts..

                  我在想一个密码变量......但这是一个合法的 CRON 命令吗?:

                  I was thinking a Password Variable.... but is this a legal CRON command? :

                  /usr/local/bin/php -f /home/mysite/public_html/dir/script?password=12345
                  

                  这样人们在通过 HTTP 访问 PHP 脚本时就无法执行相同的命令(除非他们知道密码)

                  This way people cannot be able to execute the same commands when visiting the PHP script via HTTP (unless they know the password)

                  谢谢.

                  推荐答案

                  您应该将此文件保留在 public_html 之外

                  You should keep this file outside of public_html

                  /usr/local/bin/php -f /home/mysite/script 
                  // is secure from public access
                  

                  这篇关于PHP &amp;cron:安全问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

                  上一篇:nohup:在后台运行 PHP 进程 下一篇:自定义 Laravel Artisan 命令无法通过 cron 作业使用

                  相关文章

                  <legend id='T3Ohi'><style id='T3Ohi'><dir id='T3Ohi'><q id='T3Ohi'></q></dir></style></legend>

                  <small id='T3Ohi'></small><noframes id='T3Ohi'>

                  <i id='T3Ohi'><tr id='T3Ohi'><dt id='T3Ohi'><q id='T3Ohi'><span id='T3Ohi'><b id='T3Ohi'><form id='T3Ohi'><ins id='T3Ohi'></ins><ul id='T3Ohi'></ul><sub id='T3Ohi'></sub></form><legend id='T3Ohi'></legend><bdo id='T3Ohi'><pre id='T3Ohi'><center id='T3Ohi'></center></pre></bdo></b><th id='T3Ohi'></th></span></q></dt></tr></i><div id='T3Ohi'><tfoot id='T3Ohi'></tfoot><dl id='T3Ohi'><fieldset id='T3Ohi'></fieldset></dl></div>

                    1. <tfoot id='T3Ohi'></tfoot>

                        <bdo id='T3Ohi'></bdo><ul id='T3Ohi'></ul>