public inbox for development@lists.ipfire.org
 help / color / mirror / Atom feed
From: "Peter Müller" <peter.mueller@link38.eu>
To: development@lists.ipfire.org
Subject: Re: [PATCH v2] redirect to TLS WebUI if authorisation required
Date: Wed, 11 Oct 2017 16:52:11 +0200	[thread overview]
Message-ID: <20171011165211.0042db75.peter.mueller@link38.eu> (raw)
In-Reply-To: <1507730216.4045.78.camel@ipfire.org>

[-- Attachment #1: Type: text/plain, Size: 2517 bytes --]

Well, I hope the third try is working now...

> Nope.
> 
> [root(a)rice-oxley ipfire-2.x]# pwclient git-am -s 1460
> Applying patch #1460 using 'git am -s'
> Description: [v2] redirect to TLS WebUI if authorisation required
> Applying: redirect to TLS WebUI if authorisation required
> error: corrupt patch at line 41
> Patch failed at 0001 redirect to TLS WebUI if authorisation required
> The copy of the patch that failed is found in: .git/rebase-apply/patch
> When you have resolved this problem, run "git am --continue".
> If you prefer to skip this patch, run "git am --skip" instead.
> To restore the original branch and stop patching, run "git am --abort".
> 'git am' failed with exit status 128
> 
> 
> On Wed, 2017-10-11 at 15:55 +0200, Peter Müller wrote:
> > Do not allow credentials being submitted in plaintext to Apache.
> > Instead, redirect the user with a 301 to the TLS version of IPFire's
> > web interface.
> > 
> > Signed-off-by: Peter Müller <peter.mueller(a)link38.eu>
> > ---
> > diff --git a/config/httpd/vhosts.d/ipfire-interface.conf
> > b/config/httpd/vhosts.d/ipfire-interface.conf
> > index 619f90fcc..41d10c874 100644
> > --- a/config/httpd/vhosts.d/ipfire-interface.conf
> > +++ b/config/httpd/vhosts.d/ipfire-interface.conf
> > @@ -12,36 +12,17 @@
> >          Require all granted
> >      </Directory>
> >      <DirectoryMatch "/srv/web/ipfire/html/(graphs|sgraph)">
> > -        AuthName "IPFire - Restricted"
> > -        AuthType Basic
> > -        AuthUserFile /var/ipfire/auth/users
> > -        Require user admin
> > +	Options SymLinksIfOwnerMatch
> > +	RewriteEngine on
> > +	RewriteCond %{HTTPS} off
> > +	RewriteRule (.*) https://%{SERVER_NAME}:444/$1 [R=301,L]
> >      </DirectoryMatch>
> >      ScriptAlias /cgi-bin/ /srv/web/ipfire/cgi-bin/
> >      <Directory /srv/web/ipfire/cgi-bin>
> > -        AllowOverride None
> > -        Options None
> > -        AuthName "IPFire - Restricted"
> > -        AuthType Basic
> > -        AuthUserFile /var/ipfire/auth/users
> > -        Require user admin
> > -         <Files chpasswd.cgi>
> > -            Require all granted
> > -        </Files>
> > -        <Files webaccess.cgi>
> > -            Require all granted
> > -        </Files>
> > -    </Directory>
> > +	Options SymLinksIfOwnerMatch
> > +	RewriteEngine on
> > +	RewriteCond %{HTTPS} off
> > +	RewriteRule (.*) https://%{SERVER_NAME}:444/$1 [R=301,L]
> >      </Directory>
> >      Alias /updatecache/ /var/updatecache/
> >  	<Directory /var/updatecache>  


  reply	other threads:[~2017-10-11 14:52 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-10-11 13:55 Peter Müller
2017-10-11 13:56 ` Michael Tremer
2017-10-11 14:52   ` Peter Müller [this message]
2017-10-11 20:05     ` Michael Tremer
2017-10-11 20:12       ` Peter Müller

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20171011165211.0042db75.peter.mueller@link38.eu \
    --to=peter.mueller@link38.eu \
    --cc=development@lists.ipfire.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox