NameErr: DSID-03050C55, problem 2003 (BAD_ATT_SYNTAX) when adding group with nested group
Natxo Asenjo <[email protected]> Wed, 16 Dec 2015 10:31:31 +0100
| Newsgroups | gmane.comp.lang.perl.modules.ldap |
|---|---|
| Message-ID | <CAHBEJzWdMSx4TgeEvbRps8-5kswFfCcUTLa+cNMpBY0Fn3Npmg@mail.gmail.com> |
--089e0118271e4b2c2605270092a4
Content-Type: text/plain; charset=UTF-8
hi,
creating a group with nested groups in it fails with error
NameErr: DSID-03050C55, problem 2003 (BAD_ATT_SYNTAX), data 0, best match
of:
in ldap AD 2008r2
This is the code:
my $nested_group = "HRM - Management";
my $dn = "cn=$nested_group,$test_base";
my @groups = (
"cn=hrm - management - mt,$test_base",
"cn=hrm - management - directie,$test_base"
);
my $result = $ldaptest->add(
"$dn",
attrs => [
'objectclass' => [qw/top group/],
'cn' => "cn=$nested_group",
'samAccountName' => "$nested_group",
'grouptype' => 0x80000002,
'member' => [@groups],
]
);
$result->code && warn "failed to add group $dn ", $result->error;
Adding users is no problem. Do you know what I'm doing wrong?
Thanks!
--
Groeten,
natxo
--089e0118271e4b2c2605270092a4
Content-Type: text/html; charset=UTF-8
Content-Transfer-Encoding: quoted-printable
<div dir=3D"ltr"><div>hi,<br><br></div>creating a group with nested groups =
in it fails with error <br><br clear=3D"all"><div><div><div>NameErr: DSID-0=
3050C55, problem 2003 (BAD_ATT_SYNTAX), data 0, best match of:<br><br></div=
><div>in ldap AD 2008r2<br></div><div><br>This is the code:<br><br>my $nest=
ed_group =3D "HRM - Management";<br>my $dn =3D "cn=3D$nested=
_group,$test_base";<br><br>my @groups =3D (<br>=C2=A0=C2=A0=C2=A0 &quo=
t;cn=3Dhrm - management - mt,$test_base",<br>=C2=A0=C2=A0=C2=A0 "=
cn=3Dhrm - management - directie,$test_base"<br>);<br><br>my $result =
=3D $ldaptest->add(<br>=C2=A0=C2=A0=C2=A0 "$dn",<br>=C2=A0=C2=
=A0=C2=A0 attrs =3D> [<br>=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 =
9;objectclass'=C2=A0=C2=A0=C2=A0 =3D> [qw/top group/],<br>=C2=A0=C2=
=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 'cn'=C2=A0=C2=A0=C2=A0=C2=A0=C2=
=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 =3D> "cn=3D$nested_gr=
oup",<br>=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 'samAccountNam=
e' =3D> "$nested_group",<br>=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=
=C2=A0=C2=A0 'grouptype'=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 =3D> 0x80=
000002,<br>=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 'member'=C2=
=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 =3D> [@groups],<br>=C2=A0=
=C2=A0=C2=A0 ]<br>);<br><br>$result->code && warn "failed t=
o add group $dn ", $result->error;<br><br></div><div>Adding users i=
s no problem. Do you know what I'm doing wrong?<br><br></div><div>Thank=
s!<br></div><div><br></div><div><div class=3D"gmail_signature">--<br>Groete=
n,<br>natxo</div>
</div></div></div></div>
--089e0118271e4b2c2605270092a4--