summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorLukas Reschke <lukas@statuscode.ch>2013-01-14 21:39:49 +0100
committerLukas Reschke <lukas@statuscode.ch>2013-01-14 21:39:49 +0100
commiteab6d7eb23f66ac4a662a036336b292138e4484c (patch)
treeb41d27609f143b4b99a7f22b70c2b42068941564 /lib
parent0810d80f8a0f8611ed6f7befd4442ceb9b061781 (diff)
downloadnextcloud-server-eab6d7eb23f66ac4a662a036336b292138e4484c.tar.gz
nextcloud-server-eab6d7eb23f66ac4a662a036336b292138e4484c.zip
Enhanced auth is totally unmaintained and broken
Let's remove it, it's also not secure anymore with the introduction of our API etc... (And doesn't work with ldap etc…)
Diffstat (limited to 'lib')
-rw-r--r--lib/json.php13
-rwxr-xr-xlib/util.php34
2 files changed, 0 insertions, 47 deletions
diff --git a/lib/json.php b/lib/json.php
index 5ab877540d4..c87de3e200b 100644
--- a/lib/json.php
+++ b/lib/json.php
@@ -74,19 +74,6 @@ class OC_JSON{
exit();
}
}
-
- /**
- * Check if the user verified the login with his password
- */
- public static function verifyUser() {
- if(OC_Config::getValue('enhancedauth', false) === true) {
- if(!isset($_SESSION['verifiedLogin']) OR $_SESSION['verifiedLogin'] < time()) {
- $l = OC_L10N::get('lib');
- self::error(array( 'data' => array( 'message' => $l->t('Authentication error') )));
- exit();
- }
- }
- }
/**
* Send json error msg
diff --git a/lib/util.php b/lib/util.php
index 06ae37176c1..a8576fc1057 100755
--- a/lib/util.php
+++ b/lib/util.php
@@ -361,40 +361,6 @@ class OC_Util {
}
/**
- * Check if the user verified the login with his password in the last 15 minutes
- * If not, the user will be shown a password verification page
- */
- public static function verifyUser() {
- if(OC_Config::getValue('enhancedauth', false) === true) {
- // Check password to set session
- if(isset($_POST['password'])) {
- if (OC_User::login(OC_User::getUser(), $_POST["password"] ) === true) {
- $_SESSION['verifiedLogin']=time() + OC_Config::getValue('enhancedauthtime', 15 * 60);
- }
- }
-
- // Check if the user verified his password
- if(!isset($_SESSION['verifiedLogin']) OR $_SESSION['verifiedLogin'] < time()) {
- OC_Template::printGuestPage("", "verify", array('username' => OC_User::getUser()));
- exit();
- }
- }
- }
-
- /**
- * Check if the user verified the login with his password
- * @return bool
- */
- public static function isUserVerified() {
- if(OC_Config::getValue('enhancedauth', false) === true) {
- if(!isset($_SESSION['verifiedLogin']) OR $_SESSION['verifiedLogin'] < time()) {
- return false;
- }
- }
- return true;
- }
-
- /**
* Redirect to the user default page
*/
public static function redirectToDefaultPage() {