utiliser stdmessenger
This commit is contained in:
parent
eb167d431c
commit
5fa5f718d2
|
@ -10,7 +10,7 @@ use nur\b\ValueException;
|
||||||
use nur\data\types\md_utils;
|
use nur\data\types\md_utils;
|
||||||
use nur\data\types\Metadata;
|
use nur\data\types\Metadata;
|
||||||
use nur\iter;
|
use nur\iter;
|
||||||
use nur\log;
|
use nur\sery\output\msg;
|
||||||
|
|
||||||
class LdapSearch extends Parametrable implements IteratorAggregate {
|
class LdapSearch extends Parametrable implements IteratorAggregate {
|
||||||
use Tparametrable;
|
use Tparametrable;
|
||||||
|
@ -148,7 +148,7 @@ class LdapSearch extends Parametrable implements IteratorAggregate {
|
||||||
$this->ppDeref,
|
$this->ppDeref,
|
||||||
$this->ppControls,
|
$this->ppControls,
|
||||||
]);
|
]);
|
||||||
log::debug("Searching searchbase=$args[1] filter=$args[2]");
|
msg::debug("Searching searchbase=$args[1] filter=$args[2]");
|
||||||
|
|
||||||
$scope = $this->scope;
|
$scope = $this->scope;
|
||||||
if ($scope == self::SCOPE_SUBTREE) $rr = @ldap_search(...$args);
|
if ($scope == self::SCOPE_SUBTREE) $rr = @ldap_search(...$args);
|
||||||
|
|
|
@ -3,7 +3,7 @@ namespace nur\ldap\app;
|
||||||
|
|
||||||
use nur\ldap\LdapSearch;
|
use nur\ldap\LdapSearch;
|
||||||
use nur\ldap\LdapWalker;
|
use nur\ldap\LdapWalker;
|
||||||
use nur\log;
|
use nur\sery\output\msg;
|
||||||
|
|
||||||
class LdapDeleteApp extends LdapApplication {
|
class LdapDeleteApp extends LdapApplication {
|
||||||
const ARGS = [
|
const ARGS = [
|
||||||
|
@ -27,9 +27,9 @@ class LdapDeleteApp extends LdapApplication {
|
||||||
/** @var LdapWalker $lo */
|
/** @var LdapWalker $lo */
|
||||||
$lo = $conn->search(null, $params);
|
$lo = $conn->search(null, $params);
|
||||||
while ($lo->next($first)) {
|
while ($lo->next($first)) {
|
||||||
log::action("Suppression $lo[dn]");
|
msg::action("Suppression $lo[dn]");
|
||||||
$lo->delete();
|
$lo->delete();
|
||||||
log::asuccess();
|
msg::asuccess();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -4,8 +4,8 @@ namespace nur\ldap;
|
||||||
use nur\A;
|
use nur\A;
|
||||||
use nur\b\ValueException;
|
use nur\b\ValueException;
|
||||||
use nur\config;
|
use nur\config;
|
||||||
use nur\log;
|
|
||||||
use nur\path;
|
use nur\path;
|
||||||
|
use nur\sery\output\msg;
|
||||||
use nur\SL;
|
use nur\SL;
|
||||||
|
|
||||||
abstract class ldap_server {
|
abstract class ldap_server {
|
||||||
|
@ -52,7 +52,7 @@ abstract class ldap_server {
|
||||||
static function conn(?array $config=null, ?string $profile=null): LdapConn {
|
static function conn(?array $config=null, ?string $profile=null): LdapConn {
|
||||||
if ($profile === null) $profile = self::get_profile();
|
if ($profile === null) $profile = self::get_profile();
|
||||||
$name = self::name();
|
$name = self::name();
|
||||||
log::debug("Profil $name: $profile");
|
msg::debug("Profil $name: $profile");
|
||||||
$configFile = static::fix_path(ldap_config::get_file($name, $profile));
|
$configFile = static::fix_path(ldap_config::get_file($name, $profile));
|
||||||
if (!file_exists($configFile)) {
|
if (!file_exists($configFile)) {
|
||||||
$configname = path::filename($configFile);
|
$configname = path::filename($configFile);
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
<?php
|
<?php
|
||||||
namespace nur\ldap\schemas;
|
namespace nur\ldap\schemas;
|
||||||
|
|
||||||
use nur\log;
|
use nur\sery\output\log;
|
||||||
|
|
||||||
class LseAttribute extends LseParser {
|
class LseAttribute extends LseParser {
|
||||||
protected $data;
|
protected $data;
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
<?php
|
<?php
|
||||||
namespace nur\ldap\schemas;
|
namespace nur\ldap\schemas;
|
||||||
|
|
||||||
use nur\log;
|
use nur\sery\output\log;
|
||||||
|
|
||||||
class LseObjectClass extends LseParser {
|
class LseObjectClass extends LseParser {
|
||||||
const BOOL_ATTRS = [];
|
const BOOL_ATTRS = [];
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
<?php
|
<?php
|
||||||
namespace nur\ldap\schemas;
|
namespace nur\ldap\schemas;
|
||||||
|
|
||||||
use nur\log;
|
use nur\sery\output\log;
|
||||||
|
|
||||||
class LseSyntax extends LseParser {
|
class LseSyntax extends LseParser {
|
||||||
const BOOL_ATTRS = [
|
const BOOL_ATTRS = [
|
||||||
|
|
Loading…
Reference in New Issue