ÿØÿàJFIFÿþ ÿÛC       ÿÛC ÿÀÿÄÿÄ"#QrÿÄÿÄ&1!A"2qQaáÿÚ ?Øy,æ/3JæÝ¹È߲؋5êXw²±ÉyˆR”¾I0ó2—PI¾IÌÚiMö¯–þrìN&"KgX:Šíµ•nTJnLK„…@!‰-ý ùúmë;ºgµŒ&ó±hw’¯Õ@”Ü— 9ñ-ë.²1<yà‚¹ïQÐU„ہ?.’¦èûbß±©Ö«Âw*VŒ) `$‰bØÔŸ’ëXÖ-ËTÜíGÚ3ð«g Ÿ§¯—Jx„–’U/ÂÅv_s(Hÿ@TñJÑãõçn­‚!ÈgfbÓc­:él[ðQe 9ÀPLbÃãCµm[5¿ç'ªjglå‡Ûí_§Úõl-;"PkÞÞÁQâ¼_Ñ^¢SŸx?"¸¦ùY騐ÒOÈ q’`~~ÚtËU¹CڒêV  I1Áß_ÿÙ aNc@s)dZddlmZddlZdgZddgZdefdYZdefd YZ defd YZ de fd YZ d efd YZ de fdYZde fdYZdefdYZde fdYZdefdYZdZee_dS(s Middleware to make internal requests and forward requests internally. When applied, several keys are added to the environment that will allow you to trigger recursive redirects and forwards. paste.recursive.include: When you call ``environ['paste.recursive.include'](new_path_info)`` a response will be returned. The response has a ``body`` attribute, a ``status`` attribute, and a ``headers`` attribute. paste.recursive.script_name: The ``SCRIPT_NAME`` at the point that recursive lives. Only paths underneath this path can be redirected to. paste.recursive.old_path_info: A list of previous ``PATH_INFO`` values from previous redirects. Raise ``ForwardRequestException(new_path_info)`` to do a forward (aborting the current request). i(tStringIONtRecursiveMiddlewaretForwardRequestExceptiont RecursionLoopcBseZdZRS(s*Raised when a recursion enters into a loop(t__name__t __module__t__doc__(((s@/opt/alt/python27/lib/python2.7/site-packages/paste/recursive.pyR stCheckForRecursionMiddlewarecBseZdZdZRS(cCs||_||_dS(N(tapptenv(tselfRR ((s@/opt/alt/python27/lib/python2.7/site-packages/paste/recursive.pyt__init__%s cCs|jdd}||jjdgkrMtd||jdfn|jjdg}|j|jjdd|j||S(Nt PATH_INFOtspaste.recursive.old_path_infosGForwarding loop detected; %r visited twice (internal redirect path: %s)(tgetR Rt setdefaulttappendR(R tenvirontstart_responset path_infot old_path_info((s@/opt/alt/python27/lib/python2.7/site-packages/paste/recursive.pyt__call__)s (RRR R(((s@/opt/alt/python27/lib/python2.7/site-packages/paste/recursive.pyR$s cBs#eZdZddZdZRS(s} A WSGI middleware that allows for recursive and forwarded calls. All these calls go to the same 'application', but presumably that application acts differently with different URLs. The forwarded URLs must be relative to this container. Interface is entirely through the ``paste.recursive.forward`` and ``paste.recursive.include`` environmental keys. cCs ||_dS(N(t application(R Rt global_conf((s@/opt/alt/python27/lib/python2.7/site-packages/paste/recursive.pyR AscCst|j|||djdd|d<jdd|d<|j||S(NR!iR it QUERY_STRING(tsplitR(R RR(turl(s@/opt/alt/python27/lib/python2.7/site-packages/paste/recursive.pyRs(RRR((R)(s@/opt/alt/python27/lib/python2.7/site-packages/paste/recursive.pyR&s((RR&(R"R)(s@/opt/alt/python27/lib/python2.7/site-packages/paste/recursive.pyR%scs&dffdY}||S(NtEnvironForwardcseZfdZRS(cs|j|S(N(R(R tenviron_R(R(s@/opt/alt/python27/lib/python2.7/site-packages/paste/recursive.pyRs(RRR((R(s@/opt/alt/python27/lib/python2.7/site-packages/paste/recursive.pyR*s((RR*(R"R(s@/opt/alt/python27/lib/python2.7/site-packages/paste/recursive.pyR%s( t TypeErrortwarningstwarntDeprecationWarningRtstrtobjectthasattrR(R R)RRRR%((R"RR$R)s@/opt/alt/python27/lib/python2.7/site-packages/paste/recursive.pyR s<              N(RRRR R (((s@/opt/alt/python27/lib/python2.7/site-packages/paste/recursive.pyRZs Pt RecursivecBs/eZdZddZdZdZRS(cCs.||_|j|_||_||_dS(N(Rtcopytoriginal_environtprevious_environR(R RRR((s@/opt/alt/python27/lib/python2.7/site-packages/paste/recursive.pyR s  cCs|jj}|r%|j|n|j|d<|jjd}|jdr|j|sxtd||f|t|d}n|jd std|}||dRR7(t __class__RRR5R(R ((s@/opt/alt/python27/lib/python2.7/site-packages/paste/recursive.pyt__repr__s  N(RRR R RRARG(((s@/opt/alt/python27/lib/python2.7/site-packages/paste/recursive.pyR3s   RcBseZdZdZRS(s  The forwarder will try to restart the request, except with the new `path` (replacing ``PATH_INFO`` in the request). It must not be called after and headers have been returned. It returns an iterator that must be returned back up the call stack, so it must be used like: .. code-block:: python return environ['paste.recursive.forward'](path) Meaningful transformations cannot be done, since headers are sent directly to the server and cannot be inspected or rewritten. cCs&tjdtd|j||jS(NsKrecursive.Forwarder has been deprecated; please use ForwardRequestExceptioni(R-R.R/RR(R R((s@/opt/alt/python27/lib/python2.7/site-packages/paste/recursive.pyRA.s (RRRRA(((s@/opt/alt/python27/lib/python2.7/site-packages/paste/recursive.pyRsRcBseZdZdZRS(s Starts another request with the given path and adding or overwriting any values in the `extra_environ` dictionary. Returns an IncludeResponse object. cs}tdfd}|j||}z"x|D]}j|q7WWdt|drn|jnXjS(Ncs:|r!|d|d|dn|_|_jS(Niii(tstatustheaderstwrite(RHRItexc_info(tresponse(s@/opt/alt/python27/lib/python2.7/site-packages/paste/recursive.pyR@s   tclose(tIncludedResponseR RRJR2RM(R RRtapp_iterts((RLs@/opt/alt/python27/lib/python2.7/site-packages/paste/recursive.pyRA>s   (RRRRA(((s@/opt/alt/python27/lib/python2.7/site-packages/paste/recursive.pyR6sRNcBsAeZdZdZdZdZdZeeZRS(cCs+d|_d|_t|_d|_dS(N(R RIRHRtoutputR0(R ((s@/opt/alt/python27/lib/python2.7/site-packages/paste/recursive.pyR Rs   cCs,|jj|_|jjd|_dS(N(RQtgetvalueR0RMR (R ((s@/opt/alt/python27/lib/python2.7/site-packages/paste/recursive.pyRMXs cCs/|jdk std|jj|dS(NsIThis response has already been closed and no further data can be written.(RQR R?RJ(R RP((s@/opt/alt/python27/lib/python2.7/site-packages/paste/recursive.pyRJ]s cCs|jS(N(tbody(R ((s@/opt/alt/python27/lib/python2.7/site-packages/paste/recursive.pyt__str__cscCs'|jdkr|jjS|jSdS(N(R0R RQRR(R ((s@/opt/alt/python27/lib/python2.7/site-packages/paste/recursive.pyt body__getfs ( RRR RMRJRTRUtpropertyRS(((s@/opt/alt/python27/lib/python2.7/site-packages/paste/recursive.pyRNPs      RcBseZdZdZRS(sk Like Includer, but just stores the app_iter response (be sure to call close on the response!) cs:tdfd}|j||}|_S(Ncs:|r!|d|d|dn|_|_jS(Niii(RHRIRJ(RHRIRK(RL(s@/opt/alt/python27/lib/python2.7/site-packages/paste/recursive.pyRvs   (tIncludedAppIterResponseR RRO(R RRRO((RLs@/opt/alt/python27/lib/python2.7/site-packages/paste/recursive.pyRAts   (RRRRA(((s@/opt/alt/python27/lib/python2.7/site-packages/paste/recursive.pyRnsRWcBs#eZdZdZdZRS(cCs1d|_d|_g|_d|_t|_dS(N(R RHRIt accumulatedROtFalset_closed(R ((s@/opt/alt/python27/lib/python2.7/site-packages/paste/recursive.pyR s     cCs<|j stdt|jdr8|jjndS(NsTried to close twiceRM(RZR?R2RORM(R ((s@/opt/alt/python27/lib/python2.7/site-packages/paste/recursive.pyRMs  cCs|jjdS(N(RXR(R RP((s@/opt/alt/python27/lib/python2.7/site-packages/paste/recursive.pyRJs(RRR RMRJ(((s@/opt/alt/python27/lib/python2.7/site-packages/paste/recursive.pyRWs  cCs t|S(N(R(RR((s@/opt/alt/python27/lib/python2.7/site-packages/paste/recursive.pytmake_recursive_middlewares(Rt cStringIORR-t__all__t __pudge_all__R?RR1RRt ExceptionRR3RRRNRRWR[(((s@/opt/alt/python27/lib/python2.7/site-packages/paste/recursive.pyts    %*