Mercurial > p > roundup > code
view website/www/index.txt @ 6693:9a1f5e496e6c
issue2551203 - Add support for CORS preflight request
Add support for unauthenticated CORS preflight and fix headers for
CORS.
client.py:
pass through unauthenticated CORS preflight to rest backend. Normal
rest OPTION handlers (including tracker defined extensions) can
see and handle the request.
make some error cases return error json with crrect mime type rather
than plain text tracebacks.
create new functions to verify origin and referer that filter using
allowed origins setting.
remove tracker base url from error message is referer is not at an
allowed origin.
rest.py:
fix up OPTION methods handlers to include
Access-Control-Allow-Methods that are the same as the Allow
header.
set cache to one week for all Access-Control headers for CORS
preflight only.
remove self.client.setHeader("Access-Control-Allow-Origin", "*") and
set Access-Control-Allow-Origin to the client supplied origin if
it passes allowed origin checks. Required for CORS otherwise data
isn't available to caller. Set for all responses.
set Vary header now includes Origin as responses can differ based on
Origin for all responses.
set Access-Control-Allow-Credentials to true on all responses.
test_liveserver.py:
run server with setting to enforce origin csrf header check
run server with setting to enforce x-requested-with csrf header check
run server with setting for allowed_api_origins
requests now set required csrf headers
test preflight request on collections
check new headers and Origin is no longer '*'
rewrite all compression checks to use a single method with argument
to use different compression methods. Reduce a lot of code
duplication and makes updating for new headers easier.
test_cgi:
test new error messages in client.py
account for new headers
test preflight and new code paths
| author | John Rouillard <rouilj@ieee.org> |
|---|---|
| date | Tue, 07 Jun 2022 09:39:35 -0400 |
| parents | 4eee1aa1103e |
| children | a1868fe784d0 dee99f8a386f |
line wrap: on
line source
Roundup Issue Tracker ===================== .. meta:: :title: Roundup Issue Tracker :description: A simple-to-use and -install issue-tracking system with command-line, web, REST, XML-RPC and e-mail interfaces. Adaptable to many uses cases. Allows you to customise the look and feel and implement different workflows. :og\:type: website :og\:url: https://www.roundup-tracker.org/ :og\:title: Roundup Issue Tracker :og\:description: A simple-to-use and -install issue-tracking system with command-line, web, REST, XML-RPC and e-mail interfaces. Adaptable to many uses cases. Allows you to customise the look and feel and implement different workflows. :og\:image: https://www.roundup-tracker.org/_images/index_logged_out.png .. raw:: html <div class="release_info note">Download: <a href="https://pypi.org/project/roundup/">latest</a></div> Roundup is a simple-to-use and -install issue-tracking system with command-line, web, REST, XML-RPC and e-mail interfaces. It is based on the winning design from Ka-Ping Yee in the Software Carpentry "Track" design competition. The current stable version of Roundup is 2.1.0. It is a bug fix and minor feature release for the major 2.0.0 release which added: * Python 2 and Python 3 support * a new REST interface * updates to jinja2 templates including security improvements Fixes and features in the 2.1.0 release include: * Installation uses setuptools and not distutils. * Mysql backend now uses an index to make sure that key values are not duplicated when two roundup processes run in parallel. * Postgres back end now uses a server side cursor, so large queries won't consume huge amounts of memory. * Security fixes for jQuery, markdown handling, * Valid class names are documented and enforced. All class names now match ``[A-z][A-z0-9_]+[A-z_]``. * Fixes/improvements to jinja2 templates * Fixes for python3 compatibility. * Fix sorting of multilinks in templating code. * Password reset documented in user guide. More info on the 58 changes can be found in the `change note`_. For more information on Roundup see the :doc:`design overview <docs/design>`, and all the other :doc:`documentation <docs>`. Roundup has been deployed for: * bug tracking and TODO list management (the classic installation) * customer help desk support (with a wizard for the phone answerers, linking to networking, system and development issue trackers) * issue management for IETF working groups * sales lead tracking * conference paper submission and double-blind referee management * weblogging (well, almost :) ...and so on. It's been designed with :doc:`flexibility <docs/customizing>` in mind - it's not just another bug tracker. Roundup ships with a *demo tracker* to play with - after you've unpacked the source, just run "python demo.py" and load up the URL it prints out! Roundup was originally released as version 0.1.1 in late August, 2001. The first `change note`_ written said: Needed a bug tracking system. Looked around. Tried to install many Perl-based systems, to no avail. Got tired of waiting for Roundup to be released. Had just finished major product project, so needed something different for a while. Roundup here I come... .. _`download`: https://pypi.org/project/roundup/ .. _`change note`: https://sourceforge.net/p/roundup/code/ci/tip/tree/CHANGES.txt .. _`its own set of docs`: https://www.roundup-tracker.org/dev-docs/docs.html
