From: Andrew Dolgov <fox@bah.spb.su>
Date: Sun, 20 Nov 2005 06:33:45 +0000 (+0100)
Subject: default password warning
X-Git-Tag: schema_feature_freeze_for_1.1~173
X-Git-Url: https://git.wh0rd.org/?a=commitdiff_plain;h=a029d5309fa160d6e05b93bf41049b0e649a43bd;p=tt-rss.git

default password warning
---

diff --git a/backend.php b/backend.php
index 0333e11f..0322743b 100644
--- a/backend.php
+++ b/backend.php
@@ -1724,6 +1724,16 @@
 
 			if (!SINGLE_USER_MODE) {
 
+				$result = db_query($link, "SELECT id FROM ttrss_users
+					WHERE id = ".$_SESSION["uid"]." AND (pwd_hash = 'password' OR
+						pwd_hash = 'SHA1:".sha1("password")."')");
+
+				if (db_num_rows($result) != 0) {
+					print "<div class=\"warning\"><b>Warning</b>: 
+						Your password is at default value, please change it.
+					</div>";
+				}
+
 				print "<form action=\"backend.php\" method=\"POST\">";
 	
 				print "<table width=\"100%\" class=\"prefPrefsList\">";