[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
[tor-commits] [flashproxy/master] Don't disable for Safari 6.0 and later.
commit 03d253168bb6fce49bcbd0dc77b5fe930dece8b7
Author: David Fifield <david@xxxxxxxxxxxxxxx>
Date: Fri Sep 14 22:01:09 2012 -0700
Don't disable for Safari 6.0 and later.
Safari 6 now has the newer hybi/RFC 6455 type of WebSocket. I just
tested and was able to bootstrap through Safari for the first time.
I did not find a nice in-browser way to test for the websocket type,
short of User-Agent sniffing.
---
flashproxy.js | 9 +++++----
1 files changed, 5 insertions(+), 4 deletions(-)
diff --git a/flashproxy.js b/flashproxy.js
index 32eb534..cd31f60 100644
--- a/flashproxy.js
+++ b/flashproxy.js
@@ -843,10 +843,11 @@ function flashproxy_should_disable() {
}
}
- if (ua.match(/\bsafari\b/i) && !ua.match(/\bchrome\b/i)) {
- /* Disable on Safari because it doesn't have the hybi/RFC type of
- WebSockets. */
- puts("Disable because User-Agent is Safari.");
+ if (ua.match(/\bsafari\b/i) && !ua.match(/\bchrome\b/i)
+ && !ua.match(/\bversion\/[6789]\./i)) {
+ /* Disable before Safari 6.0 because it doesn't have the hybi/RFC type
+ of WebSockets. */
+ puts("Disable because User-Agent is Safari before 6.0.");
return true;
}
_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits