Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions extension_mv2/content_scripts/cip.js
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ var cip = {

chrome.runtime.sendMessage({
'action': 'retrieve_credentials',
'args': [cip.url, cip.submitUrl, true, true]
'args': [cip.url, cip.submitUrl, true, true, mcCombs.forceFilling]
}, cip.retrieveCredentialsCallback);
},
fillUserNameOrPasswordField: function()
Expand All @@ -109,7 +109,7 @@ var cip = {

chrome.runtime.sendMessage({
'action': 'retrieve_credentials',
'args': [document.location.origin, action, true, true]
'args': [document.location.origin, action, true, true, mcCombs.forceFilling]
}, mcCombs.retrieveCredentialsCallback);
},
/**
Expand Down Expand Up @@ -312,7 +312,7 @@ var cip = {

chrome.runtime.sendMessage({
'action': 'retrieve_credentials',
'args': [cip.url, cip.submitUrl, true, true]
'args': [cip.url, cip.submitUrl, true, true, false]
}, function (credentials) {
cipDebug.log('cip.fillInCredentials()');
cip.retrieveCredentialsCallback(credentials, true);
Expand All @@ -337,8 +337,8 @@ var cip = {
*/
retrieveAndFillUserAndPassword: function ()
{
cip.initCredentialFields(true);
mcCombs.forceFilling = true;
cip.initCredentialFields(true);
},

/**
Expand Down
21 changes: 13 additions & 8 deletions extension_mv2/vendor/mooltipass/device.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,9 @@ if (typeof(safari) == 'object')
if (background_debug_msg > 4) mpDebug.log('%c Extension running in Safari', mpDebug.css('00ffff'));
mooltipass.device.browser = "safari";
}
if (window.chrome && chrome.runtime && chrome.runtime.id)
//old before MV3
//if (window.chrome && chrome.runtime && chrome.runtime.id)
if (chrome && chrome.runtime && chrome.runtime.id)
{
if (background_debug_msg > 4) mpDebug.log('%c Extension running in Chrome', mpDebug.css('00ffff'));
mooltipass.device.browser = "chrome";
Expand Down Expand Up @@ -682,7 +684,7 @@ mooltipass.device.onTabUpdated = function(tabId, removeInfo)
* @param forceCallback
* @param triggerUnlock
*/
mooltipass.device.retrieveCredentials = function(callback, tab, url, submiturl, forceCallback, triggerUnlock)
mooltipass.device.retrieveCredentials = function(callback, tab, url, submiturl, forceCallback, triggerUnlock, manualFilling)
{
if (background_debug_msg > 3) mpDebug.log('%c device: %c retrieveCredentials ','background-color: #e244ff','color: #484848', arguments);

Expand Down Expand Up @@ -731,13 +733,16 @@ mooltipass.device.retrieveCredentials = function(callback, tab, url, submiturl,
return;
}
}
if (mooltipass.device.checkInLastCredentialsRequests(tab.id, submiturl)){
mooltipass.device.addToLastCredentialsRequests(tab.id, submiturl);
return;

if (!manualFilling){
if (mooltipass.device.checkInLastCredentialsRequests(tab.id, submiturl)){
mooltipass.device.addToLastCredentialsRequests(tab.id, submiturl);
return;
}

mooltipass.device.addToLastCredentialsRequests(tab.id, submiturl);
}

mooltipass.device.addToLastCredentialsRequests(tab.id, submiturl);


// If our retrieveCredentialsQueue is empty and the device is unlocked, send the request to the app. Otherwise, queue it
mooltipass.device.retrieveCredentialsQueue.push({'tabid': tab.id, 'callback': callback, 'domain': parsed_url.domain, 'subdomain': parsed_url.subdomain, 'tabupdated': false, 'reqid': mooltipass.device.retrieveCredentialsCounter, 'tab': tab});

Expand Down
Loading