Univention Bugzilla – Attachment 8003 Details for
Bug 41641
Determination of policy types is indeterministic
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
Workaround: fix order of objectclass in every or specific policies
fixpolicy.sh (text/plain), 699 bytes, created by
Sönke Schwardt-Krummrich
on 2016-09-13 14:23:16 CEST
(
hide
)
Description:
Workaround: fix order of objectclass in every or specific policies
Filename:
MIME Type:
Creator:
Sönke Schwardt-Krummrich
Created:
2016-09-13 14:23:16 CEST
Size:
699 bytes
patch
obsolete
>#!/bin/bash ># > >if [ -z "$1" -o "$1" = "-h" -o "$1" = "--help" ] ; then > echo "$(dirname "$0") [<DN>|--all]" > exit 0 >fi > >fix_policy () { > DN="$1" > > OC="$(univention-ldapsearch -b "$DN" -s base -LLL objectClass | egrep "^objectClass: " | egrep -v "^objectClass: univentionPolicy$")" > > cat > "$FN" <<EOF >dn: $DN >changetype: modify >replace: objectClass >$OC >objectClass: univentionPolicy > >EOF > > ldapmodify -D "cn=admin,$(ucr get ldap/base)" -y /etc/ldap.secret -f "$FN" >} > >FN="$(mktemp)" > >if [ ! "$1" = "--all" ] ; then > fix_policy "$1" >else > export IFS=" >" > for dn in $(univention-ldapsearch -LLL "objectClass=univentionPolicy" dn | sed -nre 's/^dn: //p'); do > fix_policy "$dn" > done >fi > >rm -f "$FN"
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 41641
:
8003
|
8017