1. 01 Jan, 2018 1 commit
    • Leigh Stoller's avatar
      Changes to reservation system wrt classic interface: · dc90a087
      Leigh Stoller authored
      1. Reservation system now groks experiment lockdown and swappable. When
         swapping in, lockdown and swappable mean the expected end of the
         experiment is never.
      
      2. Reservation library now handles changes to lockdowm, swappable, and
         autoswap (timeout). editexp now hands these changes off to a new
         script called manage_expsettings, which can be called by hand since
         we might need to force a change (I am not changing the classic UI, if
         a change is not allowed by the res system, we have to do it by hand).
      
      3. Minor fixes to reservation library.
      dc90a087
  2. 01 May, 2014 1 commit
  3. 22 Apr, 2014 1 commit
  4. 13 Feb, 2014 1 commit
  5. 06 Nov, 2013 1 commit
  6. 19 Sep, 2013 1 commit
  7. 11 Jul, 2013 1 commit
  8. 04 Oct, 2012 1 commit
  9. 03 Oct, 2012 1 commit
  10. 24 Sep, 2012 1 commit
    • Eric Eide's avatar
      Replace license symbols with {{{ }}}-enclosed license blocks. · 6df609a9
      Eric Eide authored
      This commit is intended to makes the license status of Emulab and
      ProtoGENI source files more clear.  It replaces license symbols like
      "EMULAB-COPYRIGHT" and "GENIPUBLIC-COPYRIGHT" with {{{ }}}-delimited
      blocks that contain actual license statements.
      
      This change was driven by the fact that today, most people acquire and
      track Emulab and ProtoGENI sources via git.
      
      Before the Emulab source code was kept in git, the Flux Research Group
      at the University of Utah would roll distributions by making tar
      files.  As part of that process, the Flux Group would replace the
      license symbols in the source files with actual license statements.
      
      When the Flux Group moved to git, people outside of the group started
      to see the source files with the "unexpanded" symbols.  This meant
      that people acquired source files without actual license statements in
      them.  All the relevant files had Utah *copyright* statements in them,
      but without the expanded *license* statements, the licensing status of
      the source files was unclear.
      
      This commit is intended to clear up that confusion.
      
      Most Utah-copyrighted files in the Emulab source tree are distributed
      under the terms of the Affero GNU General Public License, version 3
      (AGPLv3).
      
      Most Utah-copyrighted files related to ProtoGENI are distributed under
      the terms of the GENI Public License, which is a BSD-like open-source
      license.
      
      Some Utah-copyrighted files in the Emulab source tree are distributed
      under the terms of the GNU Lesser General Public License, version 2.1
      (LGPL).
      6df609a9
  11. 30 Aug, 2011 1 commit
  12. 21 Sep, 2010 1 commit
  13. 08 Apr, 2010 1 commit
  14. 05 Feb, 2008 1 commit
  15. 22 May, 2007 1 commit
  16. 17 Apr, 2007 1 commit
  17. 12 Feb, 2007 1 commit
    • Leigh Stoller's avatar
      * Replace the argument processing code in all pages. Currently we rely on · 48acc8e3
      Leigh Stoller authored
        register_globals=1 to turn POST/GET/COOKIES arguments in local variables.
        This is known to be a terrible security risk, and we keep saying we are
        going to fix it, and now I am. In order to accomplish this on a
        transitional basis (since I don't want the entire web interface to stop
        working while I debug it), and because the code just needs the cleanup, I
        am doing it like this: Each page will sport new declarations at the top:
      
      	RequiredPageArguments("experiment", PAGEARG_EXPERIMENT,
                                    "template",   PAGEARG_TEMPLATE,
                                    "instance",   PAGEARG_INSTANCE,
                                    "metadata",   PAGEARG_METADATA,
                                    "osinfo",     PAGEARG_OSINFO,
                                    "image",      PAGEARG_IMAGE,
                                    "project",    PAGEARG_PROJECT,
                                    "group",      PAGEARG_GROUP,
                                    "user",       PAGEARG_USER,
      			      "node",       PAGEARG_NODE,
      			      "yesno",      PAGEARG_BOOLEAN,
      			      "message",    PAGEARG_STRING,
      			      "age",        PAGEARG_INTEGER,
                                    "cost",       PAGEARG_NUMERIC,
                                    "formfields", PAGEARG_ARRAY,
                                    "unknown",    PAGEARG_ANYTHING);
      
      	OptionalPageArguments("canceled", PAGEARG_BOOLEAN);
      
        The first token in each pair is the name of the global variable to
        set, and the second token is the type. So, for "experiment" we look at
        the URL for a pid/eid or exptidx, etc, sanity check them (safe for a
        DB query), and then try to find that experiment in the DB. If it maps
        to an experiment, set global variable $experiment to the object. Since
        its a required argument, produce an error if not supplied. Similar
        treatment for optional arguments, with the obvious difference.
      
        The goal is to have ALL argument processing in one place, consistent,
        and correct. I've found numerous places where we leak unchecked
        arguments into queries. It also cuts out a lot of duplicated code.
      
      * To make the above easier to deal with, I've been replacing lots of
        hardcoded URLS in the code of the form:
      
      	foo.php3?pid=$pid&eid=$eid ...
      
        with
      
              CreateURL("foo", $experiment)
      
        which creates and returns the neccessary url string, by looking at
        the type of its arguments (experiment, template, instance, etc.)
      
        Eventually plan to replace them all so that URL handling throughout
        the code is all defined in one place (all the new URL code is in
        url_defs.php).
      
      * I have cranked up error reporting to tell me anytime a variable is
        used before it is initialized, plus a bunch of other stuff that PHP
        deems improper. Think of it like -Wall ... and boy we get a lot of
        warnings.  A very large percentage of the diffs are to fix all these
        warnings.
      
        The warnings are currently going to /usr/testbed/log/php-errors.log,
        and I'll be adding a script to capture them each night and mail them
        to tbops. This file also gets errors (this will be a change for
        developers; rather then seeing errors and warnings dumped in the
        middle of web pages, they will go to this file instead).
      
      * Major refactoring of the code. More objects (nodes, images, osids).
        Moving tons of queries into the objects in the hopes of someday
        getting to a point where we can split the web interface onto a
        different server.  Lots of general cleanup.
      48acc8e3
  18. 20 Dec, 2006 1 commit
  19. 22 Aug, 2006 1 commit
  20. 14 Jun, 2006 1 commit
  21. 08 Sep, 2005 1 commit
  22. 02 Jun, 2005 1 commit
  23. 12 Jan, 2005 1 commit
  24. 20 Jan, 2004 1 commit
  25. 17 Nov, 2003 1 commit
    • Leigh Stoller's avatar
      Add web login attack detection/prevention. Two changes: · b1de9fb2
      Leigh Stoller authored
      * Add slots to users table to track number of failures in the last N
        seconds. If a threshold is passed (currently 4 failures in the last
        minute), the web login is disabled. Note that I do not disable the
        ops shell login at this time. Aging is passive; the values are cleared
        when login is successful, or when more then one minute has passed
        since the last failure. In other words, a burst of failures will
        disable the login, but failures over time are okay.
      
      * Add login_failures table to do exactly the same as above, except it
        is on an IP basis (REMOTE_ADDR in the server). Currently the
        threshold is 8 failures in the last two minutes, at which time all
        logins from that IP are disabled.
      
      In both cases email is sent to tbops (and the user).
      
      The constants are defined at the top of www/tbauth.in, rather then as
      site variables, to avoid pounding the DB when an attack is being
      launched.
      
      To clear a user freeze, go to the user profile page and use the
      "toggle" near the bottom.
      
      To clear an IP freeze: delete from login_failures were IP='1.1.1.1'
      b1de9fb2
  26. 07 Nov, 2003 1 commit
  27. 19 Sep, 2003 1 commit
    • Leigh Stoller's avatar
      Redo the Edit Experiment Metadata page; turned it into a standard form · 3f56ba9b
      Leigh Stoller authored
      based page that looks like the original Begin Experiment page. Be sure
      to look at the page in both admin mode and non-admin mode since I had
      some trouble determining how swappable is treated these days.
      
      Oh, added the ability to convert non-batch experiments into batch, and
      back. The experiment must be unlocked and in the swapped state to go
      in either direction.
      
      Also added the cpu_usage and mem_usage slots for editing. I added a
      comment about planetlab only, since otherwise we would just confuse
      normal users who have no idea what they mean. I could conditionalize
      them on having plab nodes, but thats difficult to figure out in the
      web page when the experiment is swapped out, so lets not worry about
      it.
      3f56ba9b
  28. 08 Aug, 2003 1 commit
  29. 17 Jul, 2003 1 commit
  30. 16 Jul, 2003 1 commit
  31. 10 Jun, 2003 1 commit
  32. 03 Jun, 2003 1 commit
  33. 29 May, 2003 1 commit
  34. 27 May, 2003 1 commit
  35. 23 Apr, 2003 1 commit
  36. 22 Apr, 2003 1 commit
  37. 11 Apr, 2003 1 commit
    • Mac Newbold's avatar
      Make swappability easy to toggle after expt creation. This hopefully will · 87045a9d
      Mac Newbold authored
      soon be used by admins only to grant swappability. For now, it is open to
      anyone who has expt modify access as well.
      
      The change is visible everywhere SHOWEXP is called, like showexp.php3 for
      instance.
      
      Also introduced toggle.php, a generic toggle script, similar to
      adminmode.php, but useful for just about anything. To add something, just
      add it to the list, specify the valid values it can have, and add its
      permission check and action. Now you don't need a different php page for
      each toggle switch. This page is already set up to take over from
      adminmode.php, but I didn't change things over just yet.
      
      (Should this go in the changelog?)
      87045a9d