for Zimbra (https://www.zimbra.com/) there is an admin soap interface we can (ab)use to provision user accounts. Unsurprisingly there is a cpan module to help us with it: http://search.cpan.org/~plobbes/ZCS-Admin-0.07/. I am a bit puzzled though on how to get to the info:
use ZCS::Admin; + + my $zimbra = ZCS::Admin->new( + proxy => 'https://host.domain.tld7071/service/admin/soap/', name => 'admin', + password => 'password', + ); + + die ZCS::Admin->faultinfo($zimbra) if !$zimbra; + + my $accountinfo = $zimbra->getaccount( name => "username\@domain\.tld" + ); print $accountinfo, "\n";
This gives me an xml document like this:
<GetAccountResponse xmlns="urn:zimbraAdmin"><account name="user@domain +.tld" id="0cf5bb57-a2e8-4e3a-9c3a-ce40d13446db"><a n="zimbraPrefCalen +darReminderMobile">FALSE</a><a n="zimbraPrefIMLogChats">TRUE</a><a n= +"zimbraDeviceLockWhenInactive">FALSE</a><a n="zimbraPrefFileSharingAp +plication">briefcase</a><a n="zimbraPrefCalendarWorkingHours">1:N:080 +0:1700,2:Y:0800:1700,3:Y:0800:1700,4:Y:0800:1700,5:Y:0800:1700,6:Y:08 +00:1700,7:N:0800:1700</a><a n="zimbraFeatureOutOfOfficeReplyEnabled"> +TRUE</a><a n="zimbraPrefCalendarViewTimeInterval">1h</a><a n="zimbraP +refComposeFormat">html</a><a n="zimbraPrefIMNotifyStatus">TRUE</a><a +n="zimbraPrefLocale">nl</a><a n="zimbraQuotaWarnPercent">90</a><a n=" +givenName">User</a><a n="zimbraPrefIMReportIdle">TRUE</a><a n="zimbra +MailHost">host.domain.tld</a><a n="zimbraFeatureMailForwardingEnabled +">TRUE</a><a n="zimbraPrefSaveToSent">TRUE</a><a n="zimbraPrefDisplay +ExternalImages">FALSE</a><a n="zimbraPrefOutOfOfficeCacheDuration">7d +</a ...... </account></GetAccountResponse>
What is the best way to get to the info? Thanks in advance?

In reply to soap parsing by natxo

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.