Skip to content

Commit

Permalink
Remove cookie password login
Browse files Browse the repository at this point in the history
  • Loading branch information
tananaev committed Nov 26, 2023
1 parent d90ec81 commit f6a9c46
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 14 deletions.
8 changes: 1 addition & 7 deletions web/app/view/dialog/Login.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright 2015 - 2017 Anton Tananaev ([email protected])
* Copyright 2015 - 2023 Anton Tananaev ([email protected])
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
Expand Down Expand Up @@ -127,12 +127,6 @@ Ext.define('Traccar.view.dialog.Login', {
specialKey: 'onSpecialKey'
},
inputAttrTpl: ['autocomplete="on"']
}, {
xtype: 'checkboxfield',
inputValue: true,
uncheckedValue: false,
reference: 'rememberField',
fieldLabel: Strings.userRemember
}, {
xtype: 'component',
html: '<iframe id="submitTarget" name="submitTarget" style="display:none"></iframe>'
Expand Down
8 changes: 1 addition & 7 deletions web/app/view/dialog/LoginController.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright 2015 - 2021 Anton Tananaev ([email protected])
* Copyright 2015 - 2023 Anton Tananaev ([email protected])
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
Expand Down Expand Up @@ -43,12 +43,6 @@ Ext.define('Traccar.view.dialog.LoginController', {
var user, password;

Check failure on line 43 in web/app/view/dialog/LoginController.js

View workflow job for this annotation

GitHub Actions / build

'user' is defined but never used

Check failure on line 43 in web/app/view/dialog/LoginController.js

View workflow job for this annotation

GitHub Actions / build

'password' is defined but never used
Ext.get('spinner').setVisible(false);
if (success) {
if (this.lookupReference('rememberField').getValue()) {
user = Ext.util.Base64.encode(this.lookupReference('userField').getValue());
password = Ext.util.Base64.encode(this.lookupReference('passwordField').getValue());
Ext.util.Cookies.set('user', user, Ext.Date.add(new Date(), Ext.Date.YEAR, 1));
Ext.util.Cookies.set('password', password, Ext.Date.add(new Date(), Ext.Date.YEAR, 1));
}
Traccar.app.setUser(Ext.decode(response.responseText));
this.fireViewEvent('login');
} else {
Expand Down

0 comments on commit f6a9c46

Please sign in to comment.