Forum Discussion
Peter_L_71637
Nimbostratus
May 07, 2014APM ActiveSync - Block or Allow DeviceID
Hello,
I'm setting up a F5 APM with ActiveSync. ActiveSync is working fine. But to add some extra security i want to allow devices by their DeviceID I followed the document "Enhancing Exchange Mobi...
Kevin_Stewart
Employee
May 07, 2014What log messages are you actually seeing?
I've added some logging below:
when HTTP_REQUEST {
Apply DeviceID restriction to all ActiveSync directory traffic
if {[HTTP::path] == "/Microsoft-Server-Activesync"} {
log local0. "Activesync URI = [HTTP::uri]"
Determine whether connection is Base64 encoded, (Windows Phone) and if necessary begin decoding process
set string_b64encoded [HTTP::query]
if { [catch { b64decode $string_b64encoded } string_b64decoded] == 0 and $string_b64decoded ne "" } {
log local0.info "Successful login with deviceID"
log local0.info "String b64decoded = $string_b64decoded"
binary scan $string_b64decoded x4H2 IDlenHEX
scan $IDlenHEX %x IDlenDEC
set IDlen { expr "$IDlenDEC * 2" }
binary scan $string_b64decoded x5H$IDlen HEXdeviceID
set string_sentid [string toupper $HEXdeviceID]
} else {
set string_sentid [string toupper [URI::query [HTTP::uri]]]
}
if { [class match $string_sentid contains devices] } {
log local0.info "Successful login with deviceID: $string_sentid"
} else {
log local0.info "Failed login with deviceID: $string_sentid"
}
}
}
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)Recent Discussions
Related Content
DevCentral Quicklinks
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
Discover DevCentral Connects
