cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
2655
Views
10
Helpful
9
Replies

msExchRecordedName - How is audio data stored in AD?

dgilbert
Level 1
Level 1

We would like to read the Unity voice name stored in AD (msExchRecordedName) and play the audio. I assume the audio is a .wav format (CCITT u-Law). Does anyone know how it is stored in AD? We've tried reading the data into a byte array using various encoding (Unicode, ASCII, UTF8, etc.), but none seems to work - the output cannot be played.

Any info would be appreciated. Thanks!

9 Replies 9

Tommer Catlin
VIP Alumni
VIP Alumni

What version unity are you running, because Unity 4.x stores all wav files in the SQL database, not Exchange or AD. So your recorded name, call handlers, etc are stored in SQL. After the messages is taken, it is stored in Exchange. AD just has the Unity attributes for routing and subscriber identifiers.

We're running 4.1. Any chance you know in which table the recorded name is stored?

Thanks!

Christopher McAlpin
Community Manager
Community Manager

From another post...

The current method for storing recorded names in Active Directory is an Octet string converted from the binary wave format. The

format is dependent upon a Microsoft attribute for Exchange called MSExchRecordedName. Binaries cannot be stored in Active Directory.

See:

http://forum.cisco.com/eforum/servlet/NetProf?page=netprof&forum=Service%20Providers&topic=Voice%20over%20IP&CommCmd=MB%3Fcmd%3Dpass_through%26location%3Doutline%40%5E1%40%40.1dd6ec25/2#selected_message

good catch! opps on my part, for some reason I thought all recorded names, etc were in SQL or a copy of them were in SQL.

Recorded names and greetings are stored on the local Unity servers hard drive in the \Commserver\Stream Files directory. The SQL database also has a path to each local subscribers recorded voice name and greeting.

In addition to this, voice names are also stored in Active Directory so that other Unity servers in the AD can get a copy of non local Unity subscribers voice names. Each Unity server stores its own copy of non local Unity subscribers voice names. They get their copy from the AD object.

dgilbert
Level 1
Level 1

We opened a TAC with Cisco and they initially informed us that the recorded name was stored in AD using UUEncode. I tried using a UUDecode algorithm but the output data was still not playable. It's possible that my UUDecode function is not correct. A second response from Cisco indicated that the recorded name was stored as an Octet string. So... still no solution.

Its UniCode base64 and you can extract it using ldifde with the '-u' switch.

http://en.wikipedia.org/wiki/Base64

Yes, that was the answer we got back from TAC. But we're using .net's DirectoryServices namespace to extract the data from AD. For some reason the directory services class does not return the same data as ldifde. Here's a bit of our test code:

Dim byteVoice() As Byte

myResultPropValueColl = myResultPropColl.Item("msExchRecordedName")

byteVoice = Text.Encoding.Unicode.GetBytes(myResultPropValueColl.Item(0))

If I stream the binary data to a file and compare it to the output from ldifde, the results are not the same. The ldifde file has additional data at the beginning and the end.

dgilbert
Level 1
Level 1

Problem solved! Basically, we had to read the Unicode data into a byte array, then convert back into an ASCII string, and then do the Base64 decoding back into a byte array. Here's the code:

Dim byteVoice() As Byte

Dim charVoice() As Char

byteVoice = Text.Encoding.Unicode.GetBytes(dsResultPropValueCol.Item(0))

charVoice = Text.Encoding.ASCII.GetString(byteVoice)

byteVoice = Convert.FromBase64CharArray(charVoice, 0, charVoice.Length)

Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community: