title: Setting msExchMailboxGuid for AD
body: <p>I'm trying to create an Exchange 2010 mailbox using php. I've read <a href="https://sourceforge.net/p/adldap/discussion/358759/thread/bea0158a/" rel="nofollow noreferrer">a thread</a> that mentions <code>msExchMailboxGuid</code> is required to create the mailbox. I'm using <a href="https://sourceforge.net/p/adldap/" rel="nofollow noreferrer">adLDAP</a> as a wrapper around the ldap functionality.</p>
  
  <p>I'm generating a guid fine, I just can't figure out how to send it so AD likes it. I am sending it the same way the format should be to search using a guid as a hex string, which I can do without a problem.</p>
  
  <p>When attempting to set that attribute, I get a <code>Constraint violation</code> for that field, which from searching seems to be a length issue.</p>
  
  <p>Here's my guid:</p>
  
  <p><code>66caeefb-dfc0-4f30-8d83-6b4d4d6198cf</code></p>
  
  <p>Here it is in UTF-8 hex:</p>
  
  <p><code>\fb\ee\ca\66\c0\df\30\4f\8d\83\6b\4d\4d\61\98\cf</code></p>
  
  <p>I've tried it as unencoded, with slashes, without slashes, with slashes escaped, plain string guid, plain string guid without dashes... How can I send it so it will be accepted?</p>
  
  <p>If I don't include <code>msExchMailboxGuid</code>, the AD account gets created successfully but no mailbox exists.</p>