46 include_once(
'Services/Radius/classes/class.ilRadiusSettings.php');
49 include_once(
'./Services/Xml/classes/class.ilXmlWriter.php');
62 $this->writer->xmlStartTag(
'Users');
67 $this->writer->xmlStartTag(
'User',
array(
'Action' =>
'Insert'));
71 $this->writer->xmlElement(
'Role',
array(
'Id' => $this->rad_settings->getDefaultRole(),
73 'Action' =>
'Assign'),
'');
75 $this->writer->xmlElement(
'Active',
array(),
"true");
76 $this->writer->xmlElement(
'TimeLimitOwner',
array(),7);
77 $this->writer->xmlElement(
'TimeLimitUnlimited',
array(),1);
78 $this->writer->xmlElement(
'TimeLimitFrom',
array(),
time());
79 $this->writer->xmlElement(
'TimeLimitUntil',
array(),
time());
80 $this->writer->xmlElement(
'AuthMode',
array(
'type' =>
'radius'),
'radius');
81 $this->writer->xmlElement(
'ExternalAccount',
array(),$a_username);
83 $this->writer->xmlEndTag(
'User');
84 $this->writer->xmlEndTag(
'Users');
85 $this->log->write(
'Radius: Started creation of user: '.$new_name);
87 include_once
'./Services/User/classes/class.ilUserImportParser.php';
89 $importParser->setXMLContent($this->writer->xmlDumpMem(
false));
90 $importParser->setRoleAssignment(
array($this->rad_settings->getDefaultRole() => $this->rad_settings->getDefaultRole()));
91 $importParser->setFolderId(7);
92 $importParser->startParsing();
__construct()
Constructor.
static _generateLogin($a_login)
generate free login by starting with a default string and adding postfix numbers
create($a_username)
Create new ILIAS account.
static _getInstance()
singleton get instance
Create styles array
The data for the language used.
Add data(end) time
Method that wraps PHPs time in order to allow simulations with the workflow.