Open PLanB2008 opened 1 year ago
Hence get_mac uses ldbsearch this seems to be wrong:
# get host's mac address from AD
# get_mac <ip|hostname|mac>
get_mac(){
local attr="sophomorixComputerMAC"
if validip "$1"; then
$LDBSEARCH "(sophomorixComputerIP=$1)" $attr | grep ^$attr | awk '{print $2}'
elif validhostname "$1"; then
$LDBSEARCH "(sophomorixDnsNodename=$(tolower $1))" $attr | grep ^$attr | awk '{print $2}'
elif validmac "$1"; then
$LDBSEARCH "($attr=$(toupper $1))" $attr | grep ^$attr | awk '{print $2}'
else
return 1
fi
}
MacAddress cant be determined in this case...
https://github.com/netzint/linuxmuster-linbo7/blob/960d1fb34287bc0fe9893b7f605f6bcc65a226ef/serverfs/usr/share/linuxmuster/linbo/linbo-remote.sh#L415