Moodle
  1. Moodle
  2. MDL-19260

Ment renewed keys fail to record in mnet_host when site name has a quote

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 1.9.5
    • Fix Version/s: 1.9.8
    • Component/s: MNet
    • Labels:
      None
    • Database:
      Any
    • Affected Branches:
      MOODLE_19_STABLE
    • Fixed Branches:
      MOODLE_19_STABLE
    • Rank:
      31686

      Description

      Needs adding

      needs adding addslashes call in replace_keys() as proposed here :

      ....
      set_config('openssl', implode('@@@@@@@@', $this->keypair), 'mnet');

      $this->name = addslashes($this->name); // <<< ALL SITE NAMES WITH QUOTES ARE PROTECTED.
      update_record('mnet_host', $this);
      error_log('New public key has been generated. It expires ' . date('Y/m/d h:i:s', $this->public_key_expires));
      }

        Issue Links

          Activity

          Hide
          Penny Leach added a comment - - edited

          fixed in stable, thanks valery for the report!

          (not needed in head)

          Show
          Penny Leach added a comment - - edited fixed in stable, thanks valery for the report! (not needed in head)

            People

            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: