How to parse msExchRecordedName from Linux?

Unanswered Question
Nov 30th, 2009
User Badges:

I'm trying to parse the recorded name attribute in Active Directory (msExchRecordedName) on a Linux system. I'm using the OpenLDAP version of ldapsearch:

% ldapsearch -x -t -h cn=username msExchRecordedName

I get the binary contents of the msExchRecordedName attribute successfully dumped to a file in /tmp.

But here's where I get stuck. This file seems to have no resemblance to an audio file. It doesn't have a WAV header, for example.

I checked the encoding format for voice recordings:

This shows up as:

Microsoft Mu-Law

I then try using the sox command to generate a wav file with this format, from the raw data:

sox -c 1 -r 8000 -t raw -U msExchRecordedName.raw recordedname.wav

But when I play this file, I get a static-filled tone. I tried this with a number of users whose name recordings should be correct, but can't get it to work.

Any suggestions on how to decode and parse this attribute?

  • 1
  • 2
  • 3
  • 4
  • 5
Overall Rating: 0 (0 ratings)
kartik_subbarao Wed, 12/02/2009 - 11:32
User Badges:

Figured it out. The binary contents of the msExchRecordedName attribute
are actually stored in UTF-8. The UTF-16LE values can be recovered with

iconv -f utf-8 -t utf-16le msexchrecordedname.raw > recordedname.wav.base64

As the extension implies, the resulting UTF-16LE file is a base64 file
which can be decoded to reveal the WAV file.



This Discussion

Related Content