[Bps-public-commit] RT-BugTracker-Public branch, master, updated. e9359b7167c293e5ecf0cba20914de10aa35003b

Thomas Sibley trs at bestpractical.com
Tue Jun 18 21:29:13 EDT 2013


The branch, master has been updated
       via  e9359b7167c293e5ecf0cba20914de10aa35003b (commit)
       via  4b5f50b1eec54fa371168c3bc2083921adeecd53 (commit)
      from  4e616df37d2a56dd4c4f5d89f50ce7c1abf18465 (commit)

Summary of changes:
 html/Public/Ticket/Attachment/WithHeaders/dhandler | 3 +++
 html/Public/Ticket/Attachment/dhandler             | 3 +++
 inc/Module/Install/RTx.pm                          | 2 +-
 lib/RT/BugTracker/Public.pm                        | 5 ++++-
 4 files changed, 11 insertions(+), 2 deletions(-)
 create mode 100644 html/Public/Ticket/Attachment/WithHeaders/dhandler
 create mode 100644 html/Public/Ticket/Attachment/dhandler

- Log -----------------------------------------------------------------
commit 4b5f50b1eec54fa371168c3bc2083921adeecd53
Author: Thomas Sibley <trs at bestpractical.com>
Date:   Tue Jun 18 18:27:40 2013 -0700

    A /Public version of /Ticket/Attachment for the benefit of curl/wget
    
    While /Ticket/Attachment urls were always accessible by the public user,
    you first had to be logged in.  Now you can take a /Ticket/Attachment
    url and request it outside the browser without being logged in.  This is
    incredibly useful for patches.

diff --git a/html/Public/Ticket/Attachment/WithHeaders/dhandler b/html/Public/Ticket/Attachment/WithHeaders/dhandler
new file mode 100644
index 0000000..3e2ea54
--- /dev/null
+++ b/html/Public/Ticket/Attachment/WithHeaders/dhandler
@@ -0,0 +1,3 @@
+<%init>
+$m->comp("/Ticket/Attachment/WithHeaders/dhandler", %ARGS);
+</%init>
diff --git a/html/Public/Ticket/Attachment/dhandler b/html/Public/Ticket/Attachment/dhandler
new file mode 100644
index 0000000..d5a013b
--- /dev/null
+++ b/html/Public/Ticket/Attachment/dhandler
@@ -0,0 +1,3 @@
+<%init>
+$m->comp("/Ticket/Attachment/dhandler", %ARGS);
+</%init>
diff --git a/lib/RT/BugTracker/Public.pm b/lib/RT/BugTracker/Public.pm
index 9c79678..98e4cfc 100644
--- a/lib/RT/BugTracker/Public.pm
+++ b/lib/RT/BugTracker/Public.pm
@@ -123,11 +123,14 @@ sub RedirectToPublic {
         return "/Public/Dist/ByMaintainer.html?Name="
                     . uri_escape($ARGS->{'Name'});
     }
+    elsif ( $path =~ '^(/+)Ticket/Attachment/' ) {
+        # Proxying through a /Public/ url lets us auto-login users
+        return "/Public$path";
+    }
 
     # otherwise, drop the user at the Public default page
     elsif (    $path !~ '^(/+)Public/'
            and $path !~ RT->Config->Get('WebNoAuthRegex')
-           and $path !~ '^(/+)Ticket/Attachment/'
            and $path !~ '^/+Helpers/Autocomplete/Queues' ) {
         return "/Public/";
     }

commit e9359b7167c293e5ecf0cba20914de10aa35003b
Author: Thomas Sibley <trs at bestpractical.com>
Date:   Tue Jun 18 18:29:01 2013 -0700

    Update M:I:RTx

diff --git a/inc/Module/Install/RTx.pm b/inc/Module/Install/RTx.pm
index abf6aea..c9fe996 100644
--- a/inc/Module/Install/RTx.pm
+++ b/inc/Module/Install/RTx.pm
@@ -8,7 +8,7 @@ no warnings 'once';
 
 use Module::Install::Base;
 use base 'Module::Install::Base';
-our $VERSION = '0.30';
+our $VERSION = '0.31';
 
 use FindBin;
 use File::Glob     ();

-----------------------------------------------------------------------



More information about the Bps-public-commit mailing list