[外掛] 密碼強度 Password security (Update 1.1.1)

Officially Approved MODs
由 phpBB Group 官方發展小組認證的 MOD!

版主: 版主管理群

版面規則
請注意!只有發表在 [2.0.x] MOD Database Releases 的外掛,才算是官方認證的外掛。
主題已鎖定
taicomjp
星球公民
星球公民
文章: 32
註冊時間: 2004-08-19 00:00

[外掛] 密碼強度 Password security (Update 1.1.1)

文章 taicomjp »

[2.0.19] Password security

代碼: 選擇全部

############################################################## 
## MOD Title: Password security
## MOD Author: Underhill < webmaster@underhill.de > (N/A) http://www.underhill.de/
## MOD Description: When a new passord is entered, the user will receive a JavaScript warning
## MOD Version: 1.1.0
## 
## Installation Level: easy
## Installation Time: 5 minutes
## Files To Edit:
##		includes/usercp_register.php
##		templates/subSilver/profile_add_body.tpl
##		language/lang_english/lang_main.php
##		language/lang_english/lang_faq.php
## Included Files: N/A
## Demo: N/A
## License: http://opensource.org/licenses/gpl-license.php GNU General Public License v2 
############################################################## 
## For security purposes, please check: http://www.phpbb.com/mods/ 
## for the latest version of this MOD. Although MODs are checked 
## before being allowed in the MODs Database there is no guarantee 
## that there are no security problems within the MOD. No support 
## will be given for MODs not found within the MODs Database which 
## can be found at http://www.phpbb.com/mods/ 
############################################################## 
## Author Notes: 
## 
## This modification was built for use with the phpBB template "subSilver"
##
## Tip: How to clear the warning after entering the new password?
## Tips-Download: http://www.underhill.de/downloads/phpbb2mods/passwordsecuritytips.txt
##
## Screenshot: http://www.underhill.de/downloads/phpbb2mods/passwordsecurity.png
## Download: http://www.underhill.de/downloads/phpbb2mods/passwordsecurity.txt
############################################################## 
## MOD History: 
## 
##   2005-12-31 - Version 1.1.0 
##		- Successfully tested with phpBB 2.0.19
##		- Added check for username (badboy4ever)
##		- Added check for emailadress
##		- Fixed some little problems with spelling and usability
## 
##   2005-12-20 - Version 1.0.2
##		- MOD Syntax changes for the phpBB MOD Database
## 
##   2005-12-15 - Version 1.0.1
##		- MOD Syntax changes for the phpBB MOD Database
## 
##   2005-12-13 - Version 1.0.0
##		- Final-Version
## 
##   2005-12-11 - Version 0.0.1c
##		- BETA-Version
## 
##   2005-11-07 - Version 0.0.1b
##		- BETA-Version
## 
##   2005-11-06 - Version 0.0.1a 
##		- ALPHA-Version
##		- Built and successfully tested with phpBB 2.0.18
## 
############################################################## 
lang_main.php
$lang['password_security_level1'] = '不安全';
$lang['password_security_level2'] = '不建議';
$lang['password_security_level3'] = '不太安全';
$lang['password_security_level4'] = '安全';
$lang['password_security_level5'] = '非常安全';
$lang['password_security_explain'] = 密碼強度:';
Demo
Screenshot
圖檔

測試密碼強度

版本: 1.1.0 (更新 03/11/06)
時間: ~ 5 分鐘
檔案: passwordsecurity110a.mod
大小: 9447 Bytes
頭像
心靈捕手
默默耕耘的老師
默默耕耘的老師
文章: 8510
註冊時間: 2004-04-30 01:54
來自: Taiwan

[分享] 中文化 & 修正

文章 心靈捕手 »

(1.1.1 版) 中文化參考:

#
#-----[ OPEN ]-----
#
language/lang_chinese_traditional_taiwan/lang_main.php

#
#-----[ FIND ]-----
#

代碼: 選擇全部

?>
#
#-----[ BEFORE, ADD ]-----
#

代碼: 選擇全部

// Password security
$lang['password_security_level1'] = '不安全的';
$lang['password_security_level2'] = '不建議的';
$lang['password_security_level3'] = '有點安全的';
$lang['password_security_level4'] = '安全的';
$lang['password_security_level5'] = '非常安全的';
$lang['password_security_explain'] = '密碼安全性:';
#
#-----[ OPEN ]-----
#
language/lang_chinese_traditional_taiwan/lang_faq.php

#
#-----[ FIND ]-----
#

代碼: 選擇全部

?>
#
#-----[ BEFORE, ADD ]-----
#

代碼: 選擇全部

// Password security
$faq[] = array("--", "密碼安全性"); 
$faq[] = array("甚麼是密碼安全性?", "這個功能, 提供您選擇密碼的建議; 它只是一個建議, 您可以自由決定是否採納."); 
$faq[] = array("如何保護密碼?", "選擇安全性密碼的小技巧:<br />- 密碼必須最少 6 個字元, 最多 32 個字元 (可以是英文字母, 數字, 標點, 或特殊符號).<br />- 密碼應該至少 4 個字元長, 和應該包含至少 2 個其他的字元, 如數字或符號.<br />- 特別的外國語文字元, 和空白, 是不建議的.<br />- 不要使用您的會員名稱或真實姓名.<br />- 不使用標準的鍵盤列, 如 \"qwerty\" 列.<br />- 密碼不要包含流行的或公共的短語, 如可以在書本, 詩詞上找到者; 也避免使用流行的媒體 (來自收音機和電視) 標語.<br />- 結合使用上述的要點, 以及小寫的字母.<br />- 選擇一個您不必為了記它, 而要寫下來的密碼."); 
#
#-----[ SAVE & CLOSE ]-----
#

(1.1.1 版) 修正參考:

安裝後, 當會員註冊或變更密碼時,
若會造成 'Script Error',
則以下的修改, 提供您參考:
#
#-----[ OPEN ]-----
#
templates/YOUR_THEME/profile_add_body.tpl

#
#-----[ FIND ]-----
#

代碼: 選擇全部

         if (pw_to_check.match(/[A-Z\孀牾酡/)) 
         { 
            counter_to_check = counter_to_check + 2; 
         } 
         if (pw_to_check.match(/[a-z\踊酅絺/)) 
         { 
            counter_to_check = counter_to_check + 1; 
         } 
         if (pw_to_check.match(/[0-9]/)) 
         { 
            counter_to_check = counter_to_check + 2; 
         } 
            if (pw_to_check.match(/[\.\,\?\!\%\*\_\#\:\;\~\\&\$\吭€\@\/\=\+\-\(\)\[\]\|\<\>]/)) 
            { 
               counter_to_check = counter_to_check + 2; 
            } 
#
#-----[ REPLACE WITH ]-----
#

代碼: 選擇全部

         if (pw_to_check.match(/[A-Z\A\O\U]/)) 
         { 
            counter_to_check = counter_to_check + 2; 
         } 
         if (pw_to_check.match(/[a-z\a\o\u\s]/)) 
         { 
            counter_to_check = counter_to_check + 1; 
         } 
         if (pw_to_check.match(/[0-9]/)) 
         { 
            counter_to_check = counter_to_check + 2; 
         } 
         if (pw_to_check.match(/[\.\,\?\!\%\*\_\#\:\;\~\\&\$\§\€\@\/\=\+\-\(\)\[\]\|\<\>]/)) 
         { 
            counter_to_check = counter_to_check + 2; 
         } 
#
#-----[ SAVE&CLOSE ]-----
#
施比受有福,祝福您好運! ^_^
歡迎光臨★★心靈捕手★★ :: 討論區
https://wang5555.dnsfor.me/phpBB3/
主題已鎖定

回到「官方認證外掛」