Nginx下只針對loggingphp進行https處理的重寫規則 nginx https 正向代理 nginx https ios訪問 https搭建 ngin

WBOY
發布: 2016-07-29 08:49:10
原創
1019 人瀏覽過

文章來源:Nginx下只針對logging.php進行https處理的重寫規則

在https server下加入以下配置:

if ($uri !~* "/logging.php$")
{
if ($uri !~* "/logging.php$")
{

{

rewrite ^/(.*)$ http://$host/$1 redirect;

}

在http server下加入以下設定:

if ($uri ~* "/logging.php$")

{

rewrite ^/(.*)$ https://$host/$1 redirect;

}

最後結果就是,使用者會且只會在存取logging.php的情況下,才會透過https存取。有效地避免了arp欺騙、嗅探等方法盜取帳號密碼的行為。

以上就介紹了Nginx下只針對loggingphp進行https處理的重寫規則,包含了nginx,https方面的內容,希望對PHP教學有興趣的朋友有所幫助。 🎜 🎜 🎜
相關標籤:
來源:php.cn
本網站聲明
本文內容由網友自願投稿,版權歸原作者所有。本站不承擔相應的法律責任。如發現涉嫌抄襲或侵權的內容,請聯絡admin@php.cn
熱門教學
更多>
最新下載
更多>
網站特效
網站源碼
網站素材
前端模板
關於我們 免責聲明 Sitemap
PHP中文網:公益線上PHP培訓,幫助PHP學習者快速成長!