Restrict access to web pages

Access to web pages can be restricted by IP address or by UGent account via CAS.

Restricting by IP address

Shielding web pages based on IP address can be done by placing a .htaccess file with rules in your web space. The dot before ".htaccess" indicates that it is a hidden file on Unix operating systems, so it is not shown in normal directory listings.

The rules in the file apply to all underlying directories. If you only want to shield a deeper directory, place the file directly in that directory.

Some examples of rules:

Allow ip address:

Require ip

Allow multiple ip addresses:

# several lines with one address
Require ip
Require ip
# line with several addresses
Require ip

Allowing full ip range:

# with a network mask
# ugent
Require ip
# eduroam
Require ip
# variant by specifying only the common part
Require ip 157.193.1
# this is similar to
Require ip

More info

Restricting based on UGent account

With CAS, UGent's Central Authentication Service, you can make web pages accessible only to users with a UGent account.

Easily activate CAS authentication on webhares.