× NETGEAR will be terminating ReadyCLOUD service by July 1st, 2023. For more details click here.
Orbi WiFi 7 RBE973
Reply

Redirect admin page to HTTPs?

dsnpevl
Virtuoso

Redirect admin page to HTTPs?

Hi Forum,

 

I installed 6.4.0 without issues.

However, the admin page is now exposed to the Internet on HTTP, which I see as a potential security risk.

 

Is there a way to point the http://somedomain.nl/ to a webshare and point http://somedomain.nl/admin to https://somedomain.nl/admin?

This would block remote access to the admin pages, because HTTPS is not allowed on the router.

On the internal network, I would still be able to connect to the admin pages via HTTPS.

Message 1 of 2

Accepted Solutions
dsnpevl
Virtuoso

Re: Redirect admin page to HTTPs?

Figgered it out. Let's say you have created a webshare directory from the Admin page, called "your_webshare_dir".

 

vi /etc/frontview/apache/Shares.conf

Change

Alias "/your_webshare_dir" "/data/your_webshare_dir"
<Location "/your_webshare_dir">
  Options Indexes +Includes
  Order allow,deny
  Allow from all
  Options -ExecCGI
  AllowOverride None
</Location>
to:
AliasMatch "^/(?!apps/.*)(.*)$" "/data/your_webshare_dir/$1"
<Location "/">
  Options Indexes +Includes
  Order allow,deny
  Allow from all
  Options -ExecCGI
  AllowOverride None
</Location>

This will redirect anything except the icons of the apps in the Admin page to your webshare.

 

vi /etc/frontview/apache/http-share-redirect.conf
RewriteEngine on
#RewriteRule ^/$ /admin [R,L]

This will disable the auto-redirect to the admin page when going to http://your.domain.com/.

 

vi /etc/apache2/sites-available/fv-http-admin
<VirtualHost *:80>
Include "/etc/frontview/apache/defaults.conf" Include "/etc/frontview/apache/http-redirect.conf" Include "/etc/frontview/apache/http-share-redirect.conf" Include "/etc/frontview/apache/fv-admin.conf" Include "/etc/frontview/apache/Shares.conf" Include "/etc/frontview/apache/apps-https.conf" Include "/etc/frontview/apache/READYDROP.conf" Include "/etc/frontview/apache/lan-try.conf"
</VirtualHost>

Make sure http-redirect.conf is included in the list of configurations.
(Note: not sure why this is needed, but this way it works for me.)

 

Disclaimer: Use this at your own risk.
Known issues: these setting changes will be overwritten when doing a firmware upgrade.

 

View solution in original post

Message 2 of 2

All Replies
dsnpevl
Virtuoso

Re: Redirect admin page to HTTPs?

Figgered it out. Let's say you have created a webshare directory from the Admin page, called "your_webshare_dir".

 

vi /etc/frontview/apache/Shares.conf

Change

Alias "/your_webshare_dir" "/data/your_webshare_dir"
<Location "/your_webshare_dir">
  Options Indexes +Includes
  Order allow,deny
  Allow from all
  Options -ExecCGI
  AllowOverride None
</Location>
to:
AliasMatch "^/(?!apps/.*)(.*)$" "/data/your_webshare_dir/$1"
<Location "/">
  Options Indexes +Includes
  Order allow,deny
  Allow from all
  Options -ExecCGI
  AllowOverride None
</Location>

This will redirect anything except the icons of the apps in the Admin page to your webshare.

 

vi /etc/frontview/apache/http-share-redirect.conf
RewriteEngine on
#RewriteRule ^/$ /admin [R,L]

This will disable the auto-redirect to the admin page when going to http://your.domain.com/.

 

vi /etc/apache2/sites-available/fv-http-admin
<VirtualHost *:80>
Include "/etc/frontview/apache/defaults.conf" Include "/etc/frontview/apache/http-redirect.conf" Include "/etc/frontview/apache/http-share-redirect.conf" Include "/etc/frontview/apache/fv-admin.conf" Include "/etc/frontview/apache/Shares.conf" Include "/etc/frontview/apache/apps-https.conf" Include "/etc/frontview/apache/READYDROP.conf" Include "/etc/frontview/apache/lan-try.conf"
</VirtualHost>

Make sure http-redirect.conf is included in the list of configurations.
(Note: not sure why this is needed, but this way it works for me.)

 

Disclaimer: Use this at your own risk.
Known issues: these setting changes will be overwritten when doing a firmware upgrade.

 

Message 2 of 2
Top Contributors
Discussion stats
  • 1 reply
  • 2810 views
  • 0 kudos
  • 1 in conversation
Announcements