c - Obtain peferred domain controller (Active Directory) in Mac OS X programmatically -


i'd preferred domain controller name/adress on mac, joined active directory (ms windows server domain controller) programmatically c/objective-c. better solution parsing output of dsconfigad -show commandline utility such lines:

advanced options - administrative   preferred domain controller    = 192.168.xxx.xxx 

i tried open directory api, adviced here, fails access nodes far full name of domain:

// domainnode: "/active directory/mydomain/mydomain.local" nsarray *domainsubnodes = [domainnode subnodenamesandreturnerror:&err]; [domainsubnodes count]; // count 0 

do need perform kind of authorization access subnodes of domain , how perform it? there posix/bsd functions can obtain domain controller name pure c code?


Comments

Popular posts from this blog

Why does Ruby on Rails generate add a blank line to the end of a file? -

keyboard - Smiles and long press feature in Android -

node.js - Bad Request - node js ajax post -