From 93f6c6c06f5fad3be41391fc812e8c8ad50e6b57 Mon Sep 17 00:00:00 2001 From: Carlos Moreno Date: Fri, 17 Feb 2017 21:37:46 -0600 Subject: [PATCH 1/2] Adding skype to SNEAKY_USER_AGENTS --- snappass/main.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/snappass/main.py b/snappass/main.py index 30f6926..c3e16d7 100644 --- a/snappass/main.py +++ b/snappass/main.py @@ -9,7 +9,7 @@ from redis.exceptions import ConnectionError from flask import abort, Flask, render_template, request -SNEAKY_USER_AGENTS = ('Slackbot', 'facebookexternalhit', 'Twitterbot', 'Facebot', 'WhatsApp') +SNEAKY_USER_AGENTS = ('Slackbot', 'facebookexternalhit', 'Twitterbot', 'Facebot', 'WhatsApp', 'SkypeUriPreview') SNEAKY_USER_AGENTS_RE = re.compile('|'.join(SNEAKY_USER_AGENTS)) NO_SSL = os.environ.get('NO_SSL', False) app = Flask(__name__) From e0a03dc484662c8f09d9263698cacb5fa4c0115d Mon Sep 17 00:00:00 2001 From: Carlos Moreno Date: Fri, 17 Feb 2017 21:48:10 -0600 Subject: [PATCH 2/2] added skype to sneaky_bots test --- tests.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tests.py b/tests.py index bc5e709..9203f15 100644 --- a/tests.py +++ b/tests.py @@ -85,7 +85,8 @@ class SnapPassRoutesTestCase(TestCase): "Facebot/1.0", "Twitterbot/1.0", "_WhatsApp/2.12.81 (Windows NT 6.1; U; es-ES) Presto/2.9.181 Version/12.00", - "WhatsApp/2.16.6/i" + "WhatsApp/2.16.6/i", + "SkypeUriPreview Preview/0.5" ] for ua in a_few_sneaky_bots: