Moodle

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

Details

  • Type: Bug Bug
  • Status: Closed 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

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

Vote (0)
Watch (1)

Dates

  • Created:
    Updated:
    Resolved: