Path: csiph.com!usenet.pasdenom.info!goblin2!goblin.stu.neva.ru!newsfeed.xs4all.nl!newsfeed3.news.xs4all.nl!xs4all!post.news.xs4all.nl!not-for-mail Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.017 X-Spam-Evidence: '*H*': 0.97; '*S*': 0.00; 'cache': 0.07; 'needed,': 0.07; 'session.': 0.07; 'assumed': 0.09; 'cherrypy': 0.09; 'definition,': 0.09; 'forms,': 0.09; 'latter': 0.09; 'links.': 0.09; 'refresh': 0.09; 'subject:Cherrypy': 0.09; 'cc:addr:python- list': 0.11; 'caches': 0.16; 'wrote:': 0.18; 'all,': 0.19; 'app': 0.19; 'trying': 0.19; 'typing': 0.19; 'admin': 0.22; 'cc:addr:python.org': 0.22; 'earlier': 0.24; 'mon,': 0.24; 'cc:2**0': 0.24; 'cc:no real name:2**0': 0.24; 'least': 0.26; 'primary': 0.26; 'skip:" 20': 0.27; 'header:In-Reply-To:1': 0.27; 'am,': 0.29; 'dec': 0.30; 'said,': 0.30; 'skip:( 20': 0.30; 'url:mailman': 0.30; 'request,': 0.31; 'thanks!': 0.32; 'url:python': 0.33; 'actual': 0.34; 'could': 0.34; 'problem': 0.35; 'etc': 0.35; 'acceptable': 0.36; 'are,': 0.36; 'url:listinfo': 0.36; 'url:org': 0.36; 'example,': 0.37; 'received:10': 0.37; 'server': 0.38; 'form,': 0.38; 'url:mail': 0.40; 'how': 0.40; 'even': 0.60; 'tell': 0.60; 'mentioned': 0.61; 'browser': 0.61; 'strictly': 0.61; 'simple': 0.61; 'header :Message-Id:1': 0.63; 'skip:n 10': 0.64; 'skip:\xe2 10': 0.65; 'side': 0.67; 'between': 0.67; '8bit%:100': 0.72; 'designers': 0.74; 'received:12': 0.81; '2014,': 0.84; 'harmful': 0.84; 'effects.': 0.91; 'serious': 0.97 X-Warning: RFC compliance checks disabled due to whitelist X-Warning: Reverse-Path DNS check skipped due to whitelist X-Warning: Maximum message size check skipped due to whitelist X-Warning: Realtime Block Lists skipped due to whitelist X-Warning: System filters skipped due to whitelist X-Warning: Domain filters skipped due to whitelist X-Warning: User filters skipped due to whitelist X-Warning: Anti-Spam check skipped due to whitelist X-Whitelist: 2147483645 X-Envelope-From: israel@ravnalaska.net X-Envelope-To: random832@fastmail.us Content-Type: text/plain; charset=utf-8 Mime-Version: 1.0 (Mac OS X Mail 8.1 \(1993\)) Subject: Re: Cherrypy - prevent browser "prefetch"? From: Israel Brewster In-Reply-To: <1417527181.1832828.197804893.3AA95580@webmail.messagingengine.com> Date: Tue, 2 Dec 2014 06:59:58 -0900 Content-Transfer-Encoding: quoted-printable References: <6B74D6DD-A597-4BCF-8586-D0A56C9CDB77@ravnalaska.net> <1417527181.1832828.197804893.3AA95580@webmail.messagingengine.com> To: random832@fastmail.us X-Mailer: Apple Mail (2.1993) Cc: python-list@python.org X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Newsgroups: comp.lang.python Message-ID: Lines: 40 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1417536013 news.xs4all.nl 2961 [2001:888:2000:d::a6]:51853 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:81803 > On Dec 2, 2014, at 4:33 AM, random832@fastmail.us wrote: >=20 > On Mon, Dec 1, 2014, at 15:28, Israel Brewster wrote: >> For example, I have a URL on my Cherrypy app that updates some local >> caches. It is accessed at http:///admin/updatecaches So if I >> start typing http:///a, for example, safari may auto-fill the >> "dmin/updatecaches", and trigger a cache refresh on the server - even >> though I was just trying to get to the main admin page at /admin. Or, = it >> might auto-fill "uth/logout" instead (http:///auth/logout), = and >> log me out of my session. While the former may be acceptable (after = all, >> a cache update, even if not strictly needed, is at least = non-harmfull), >> the latter could cause serious issues with usability. So how can = cherrypy >> tell the difference between the "prefetch" and an actual request, and = not >> respond to the prefetch? >=20 > Why is your logout form - or, your update caches form, etc - a GET > instead of a POST? Primary because they aren=E2=80=99t forms, they are links. And links = are, by definition, GET=E2=80=99s. That said, as I mentioned in earlier = replies, if using a form for a simple link is the Right Way to do things = like this, then I can change it. Thanks! =E2=80=94=E2=80=94=E2=80=94=E2=80=94=E2=80=94 Israel Brewster > The key problem is that a GET request is assumed by > browser designers to not have any harmful side effects. > --=20 > https://mail.python.org/mailman/listinfo/python-list