#40722 [NEW]: future request:add "safe eval" function

Ask a Question related to PHP Bugs, Design and Development.

  1. #1

    Default #40722 [NEW]: future request:add "safe eval" function

    From: shimon at schoolportal dot co dot il
    Operating system: na
    PHP version: 4.4.5
    PHP Bug Type: Feature/Change Request
    Bug description: future request:add "safe eval" function

    Description:
    ------------
    i would be cool to have a "safe eval" function
    for example:
    eval($code, $safe=true,$safe_alow,$safe_disalow ,or $safe_ini_settings);

    i do want users to insert some code to use database and simple php
    in their free web site to create info boxes and small website components
    or php in their site templates. but i want to stay safe.


    --
    Edit bug report at [url]http://bugs.php.net/?id=40722&edit=1[/url]
    --
    Try a CVS snapshot (PHP 4.4): [url]http://bugs.php.net/fix.php?id=40722&r=trysnapshot44[/url]
    Try a CVS snapshot (PHP 5.2): [url]http://bugs.php.net/fix.php?id=40722&r=trysnapshot52[/url]
    Try a CVS snapshot (PHP 6.0): [url]http://bugs.php.net/fix.php?id=40722&r=trysnapshot60[/url]
    Fixed in CVS: [url]http://bugs.php.net/fix.php?id=40722&r=fixedcvs[/url]
    Fixed in release: [url]http://bugs.php.net/fix.php?id=40722&r=alreadyfixed[/url]
    Need backtrace: [url]http://bugs.php.net/fix.php?id=40722&r=needtrace[/url]
    Need Reproduce Script: [url]http://bugs.php.net/fix.php?id=40722&r=needscript[/url]
    Try newer version: [url]http://bugs.php.net/fix.php?id=40722&r=oldversion[/url]
    Not developer issue: [url]http://bugs.php.net/fix.php?id=40722&r=support[/url]
    Expected behavior: [url]http://bugs.php.net/fix.php?id=40722&r=notwrong[/url]
    Not enough info: [url]http://bugs.php.net/fix.php?id=40722&r=notenoughinfo[/url]
    Submitted twice: [url]http://bugs.php.net/fix.php?id=40722&r=submittedtwice[/url]
    register_globals: [url]http://bugs.php.net/fix.php?id=40722&r=globals[/url]
    PHP 3 support discontinued: [url]http://bugs.php.net/fix.php?id=40722&r=php3[/url]
    Daylight Savings: [url]http://bugs.php.net/fix.php?id=40722&r=dst[/url]
    IIS Stability: [url]http://bugs.php.net/fix.php?id=40722&r=isapi[/url]
    Install GNU Sed: [url]http://bugs.php.net/fix.php?id=40722&r=gnused[/url]
    Floating point limitations: [url]http://bugs.php.net/fix.php?id=40722&r=float[/url]
    No Zend Extensions: [url]http://bugs.php.net/fix.php?id=40722&r=nozend[/url]
    MySQL Configuration Error: [url]http://bugs.php.net/fix.php?id=40722&r=mysqlcfg[/url]
    shimon at schoolportal dot co dot il Guest

  2. Similar Questions and Discussions

    1. Is XFA forms an "Open" standard, and is FDFalive for foreseeable future ?
      further to my other (first) post "Adobe PDF XML Forms ? Reading user-entered data to and from the form using VB.NET?" .... I've been researching...
    2. Is Director "future save"?
      I planning do develop mid-sized games an applications, and found Director useful for that, as far as I can see. The only problem I have is, that I...
    3. Request.Form("Field Name") Versus Request.QueryString("Field Name")
      I want to know what's the differences between Request.Form("Field Name") and Request.QueryString("Field Name") OR they function exactly the...
    4. "NBF"/The Next "Big" Format - The Near Future..
      Its seems that roughly every 5-10? years there comes out a new consumer format as an "alternate" to 35mm equipment for amature use. (Not including...
    5. Curious about XP's "future" activation...
      "Bruce Chambers" <bchambers@nospam.cableone.net> squirted these wordjisms deep inside the bumtube of the newstwat in news:vfp86t7m6rin14...
  3. #2

    Default #40722 [Opn->Bgs]: future request:add "safe eval" function

    ID: 40722
    Updated by: [email]tony2001@php.net[/email]
    Reported By: shimon at schoolportal dot co dot il
    -Status: Open
    +Status: Bogus
    Bug Type: Feature/Change Request
    Operating System: na
    PHP Version: 4.4.5
    New Comment:

    I'm afraid we'll never go this route again.
    You have to manage privileges using your OS utilities, not PHP.
    Also, the meaining of "safety" is quite dim in this particular case, so
    I can't just imagine a function that would be safe _for everyone_ and
    useable _for everyone_ without having a bunch of arguments or INI
    options.


    Previous Comments:
    ------------------------------------------------------------------------

    [2007-03-05 05:56:47] shimon at schoolportal dot co dot il

    Description:
    ------------
    i would be cool to have a "safe eval" function
    for example:
    eval($code, $safe=true,$safe_alow,$safe_disalow ,or
    $safe_ini_settings);

    i do want users to insert some code to use database and simple php
    in their free web site to create info boxes and small website
    components or php in their site templates. but i want to stay safe.



    ------------------------------------------------------------------------


    --
    Edit this bug report at [url]http://bugs.php.net/?id=40722&edit=1[/url]
    tony2001@php.net Guest

Posting Permissions

  • You may not post new threads
  • You may post replies
  • You may not post attachments
  • You may not edit your posts

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139