Fixed a bug with status text. Added some licence and updated the README.

This commit is contained in:
varjolintu 2017-05-19 15:48:17 +03:00
parent e13bb8e082
commit 301f04a2eb
13 changed files with 36 additions and 16 deletions

View file

@ -18,6 +18,39 @@ You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
```
The following quick method to determine which browser is used with API calls by [David Rousset](https://github.com/davrous):
```javascript
window.browser = (function () {
return window.msBrowser ||
window.browser ||
window.chrome;
})();
```
```
MIT License
Copyright (c) 2016 David Rousset
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
```
## Protocol
Transmitting messages between KeePassXC and chromeKeePassXC is totally rewritten. This is still under development.

View file

@ -1,4 +1,3 @@
// This quick method Copyright (c) 2016 David Rousset
window.browser = (function () {
return window.msBrowser ||
window.browser ||

View file

@ -1,4 +1,3 @@
// This quick method Copyright (c) 2016 David Rousset
window.browser = (function () {
return window.msBrowser ||
window.browser ||

View file

@ -11,7 +11,6 @@ keepass.changePublicKeys(null, function(pkRes) {
keepass.getDatabaseHash(function(gdRes) {}, null);
});
// This quick method Copyright (c) 2016 David Rousset
window.browser = (function () {
return window.msBrowser ||
window.browser ||

View file

@ -20,7 +20,6 @@ keepass.keyRing = (typeof(localStorage.keyRing) == 'undefined') ? {} : JSON.pars
keepass.keyId = "chromekeepassxc-cryptokey-name";
keepass.keyBody = "chromekeepassxc-key";
// This quick method Copyright (c) 2016 David Rousset
window.browser = (function () {
return window.msBrowser ||
window.browser ||
@ -447,11 +446,12 @@ keepass.testAssociation = function (callback, tab, triggerUnlock) {
keepass.getDatabaseHash = function (callback, tab, triggerUnlock) {
if (!keepass.isConnected) {
page.tabs[tab.id].errorMessage = "Not connected with KeePassXC.";
callback([]);
return;
}
if (!keepass.serverPublicKey) {
keepass.changePublicKeys(tab, null);
keepass.changePublicKeys(tab, function(res) {});
}
var message = { "action": "get-databasehash" };

View file

@ -1,4 +1,3 @@
// This quick method Copyright (c) 2016 David Rousset
window.browser = (function () {
return window.msBrowser ||
window.browser ||

View file

@ -1,4 +1,3 @@
// This quick method Copyright (c) 2016 David Rousset
window.browser = (function () {
return window.msBrowser ||
window.browser ||

View file

@ -1,4 +1,3 @@
// This quick method Copyright (c) 2016 David Rousset
window.browser = (function () {
return window.msBrowser ||
window.browser ||

View file

@ -1,4 +1,3 @@
// This quick method Copyright (c) 2016 David Rousset
window.browser = (function () {
return window.msBrowser ||
window.browser ||
@ -25,12 +24,10 @@ function status_response(r) {
$('#need-reconfigure-message').html(r.error);
}
else if(!r.associated) {
//$('#configured-not-associated').show();
//$('#unassociated-identifier').html(r.identifier);
$('#need-reconfigure').show();
$('#need-reconfigure-message').html(r.error);
}
else if(typeof(r.error) != "undefined") {
else if(typeof(r.error) != "undefined" || r.error != null) {
$('#error-encountered').show();
$('#error-message').html(r.error);
}

View file

@ -1,4 +1,3 @@
// This quick method Copyright (c) 2016 David Rousset
window.browser = (function () {
return window.msBrowser ||
window.browser ||

View file

@ -1,4 +1,3 @@
// This quick method Copyright (c) 2016 David Rousset
window.browser = (function () {
return window.msBrowser ||
window.browser ||

View file

@ -1,4 +1,3 @@
// This quick method Copyright (c) 2016 David Rousset
window.browser = (function () {
return window.msBrowser ||
window.browser ||

View file

@ -1,4 +1,3 @@
// This quick method Copyright (c) 2016 David Rousset
window.browser = (function () {
return window.msBrowser ||
window.browser ||