From 5b44148decca922d4540055b54cb3b8747a47643 Mon Sep 17 00:00:00 2001 From: luckyrat Date: Fri, 24 May 2024 10:38:08 +0100 Subject: [PATCH] Incrementing version to 4.0 The MV3 migration contains so many moving parts it probably has a higher risk of rollback problems than normal, so despite the lack of visual fanfare it's probably worthy of a major version bump. --- _locales/en/messages.json | 2 +- package-lock.json | 4 ++-- package.json | 2 +- src/background/KF.ts | 4 ++-- src/common/ConfigManager.ts | 2 +- src/common/DefaultSiteConfig.ts | 2 +- src/common/IPCPiniaPlugin.ts | 2 +- src/common/model/Entry.ts | 2 +- src/common/model/EntrySummary.ts | 2 +- src/common/model/Locator.ts | 2 +- src/page/formFilling.ts | 24 ++++++++++++------------ src/page/formSaving.ts | 8 ++++---- src/page/formsUtils.ts | 4 ++-- src/panels/main.ts | 2 +- src/panels/mainLegacy.ts | 2 +- src/popup/components/Save1stParty.vue | 2 +- src/release-notes/update-notes.html | 6 +++--- src/typedefs/kee.d.ts | 2 +- 18 files changed, 37 insertions(+), 37 deletions(-) diff --git a/_locales/en/messages.json b/_locales/en/messages.json index b95baec3..72f4e36b 100644 --- a/_locales/en/messages.json +++ b/_locales/en/messages.json @@ -823,7 +823,7 @@ "message": "Always save new entries here", "description": "Description of checkbox that when enabled will change a setting such that the user is not prompted where to save future entries they create." }, - "list_version_upgrade_3_12": { + "list_version_upgrade_4_0": { "message": "Support for the latest web browsers (MV3);Faster connection to KeePass on some systems (requires KeePassRPC.plgx v2+);Lots of bug fixes and probably some new bugs introduced", "description": "Changes for the version number in the string key name. Multiple items MUST be separated by a semicolon (;). Do not use a semi-colon except as a list-item (new line) separator." }, diff --git a/package-lock.json b/package-lock.json index 86d3ae2e..734cda65 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "kee-browser-addon", - "version": "3.12.0", + "version": "4.0.0", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "kee-browser-addon", - "version": "3.12.0", + "version": "4.0.0", "devDependencies": { "@ffflorian/jszip-cli": "^3.6.3", "@gorhill/publicsuffixlist": "^3.0.1", diff --git a/package.json b/package.json index 03ec4849..240602c8 100644 --- a/package.json +++ b/package.json @@ -2,7 +2,7 @@ "name": "kee-browser-addon", "displayName": "Kee - Password Manager", "description": "Kee adds private, secure and easy password management features which save time and keep your private data more secure.", - "version": "3.12.0", + "version": "4.0.0", "type": "module", "devDependencies": { "@ffflorian/jszip-cli": "^3.6.3", diff --git a/src/background/KF.ts b/src/background/KF.ts index 1e4880d7..e1b8eea5 100644 --- a/src/background/KF.ts +++ b/src/background/KF.ts @@ -465,7 +465,7 @@ class Kee { } updateKeePassDatabases(newDatabases: Database[]) { - //TODO:4: To improve performance we might need to determine if anything + //TODO:5: To improve performance we might need to determine if anything // has actually changed before doing the dispatches and poking the // current tab frames to find entries let newDatabaseActiveIndex = -1; @@ -508,7 +508,7 @@ class Kee { private refreshFormStatus(action: Action) { this.tabStates.forEach((ts, tabId) => { - //TODO:4: This should be equivalent but much faster than testing in the inner + //TODO:5: This should be equivalent but much faster than testing in the inner // loop. Unless tabId does not equal port.sender.tab.id? //if (tabId !== this.foregroundTabId) return; diff --git a/src/common/ConfigManager.ts b/src/common/ConfigManager.ts index 09f39785..2b8d3a22 100644 --- a/src/common/ConfigManager.ts +++ b/src/common/ConfigManager.ts @@ -165,7 +165,7 @@ export class ConfigManager { if (nextPage) configString += nextPage; } if (configString) this.current = JSON.parse(configString); - //TODO:4: Delete the old keefox prefixed data to save space + //TODO:5: Delete the old keefox prefixed data to save space } } this.fixInvalidConfigData(); diff --git a/src/common/DefaultSiteConfig.ts b/src/common/DefaultSiteConfig.ts index dc300581..acb8ab7e 100644 --- a/src/common/DefaultSiteConfig.ts +++ b/src/common/DefaultSiteConfig.ts @@ -5,7 +5,7 @@ defaultSiteConfig.pageRegex = new SiteConfigLookup(); defaultSiteConfig.pageRegex["^.*$"] = { config: { - /* TODO:4: ? In future we can give finer control of form rescanning behaviour from here + /* TODO:5: ? In future we can give finer control of form rescanning behaviour from here rescanDOMevents: [{ diff --git a/src/common/IPCPiniaPlugin.ts b/src/common/IPCPiniaPlugin.ts index 4da66967..3dcc82bf 100644 --- a/src/common/IPCPiniaPlugin.ts +++ b/src/common/IPCPiniaPlugin.ts @@ -6,7 +6,7 @@ import { Mutation } from "../store/Mutation"; export function IPCPiniaPlugin() { return { distributeAction: (mutation: Mutation) => { - //TODO:4: Find a way to more efficiently distribute Pinia Patch objects / Vue3 Proxy objects without this additional JSON mapping / manipulation + //TODO:5: Find a way to more efficiently distribute Pinia Patch objects / Vue3 Proxy objects without this additional JSON mapping / manipulation const json = JSON.stringify(mutation); KeeLog.debug("New non-background mutation/action going to be distributed."); Port.postMessage({ mutation: JSON.parse(json) } as AddonMessage); diff --git a/src/common/model/Entry.ts b/src/common/model/Entry.ts index 6fc260b4..c7f1dda5 100644 --- a/src/common/model/Entry.ts +++ b/src/common/model/Entry.ts @@ -46,7 +46,7 @@ export class Entry { // How relevant this entry is to the current form in // the browser - transient (not stored in KeePass) - //TODO:4 put all match data into a new object? + //TODO:5 put all match data into a new object? relevanceScore: number; lowFieldMatchRatio: any; formIndex: number; diff --git a/src/common/model/EntrySummary.ts b/src/common/model/EntrySummary.ts index d63daf8b..54a3ef73 100644 --- a/src/common/model/EntrySummary.ts +++ b/src/common/model/EntrySummary.ts @@ -14,7 +14,7 @@ export class EntrySummary { uuid: string; dbFileName: string; relevanceScore: number; - fullDetails?: Entry; //TODO:4: remove circular reference by maintaining independent Entry lookup by uuid? + fullDetails?: Entry; //TODO:5: remove circular reference by maintaining independent Entry lookup by uuid? isPreferredMatch?: boolean; constructor(e: Partial) { diff --git a/src/common/model/Locator.ts b/src/common/model/Locator.ts index 469770a2..a96175bd 100644 --- a/src/common/model/Locator.ts +++ b/src/common/model/Locator.ts @@ -26,5 +26,5 @@ export class Locator { this.autocompleteValues = locator.autocompleteValues; } - //TODO:4: Things like MaxLength that can be used to both help identify the field and generate new values/passwords + //TODO:5: Things like MaxLength that can be used to both help identify the field and generate new values/passwords } diff --git a/src/page/formFilling.ts b/src/page/formFilling.ts index 3e40987d..e48df329 100644 --- a/src/page/formFilling.ts +++ b/src/page/formFilling.ts @@ -169,7 +169,7 @@ export class FormFilling { private calculateFieldMatchScore( matchedField: MatchedField, dataField: Field, - _currentPage, //TODO:4: remove param + _currentPage, //TODO:5: remove param config: FieldMatchScoreConfig, isVisible?: boolean ) { @@ -359,7 +359,7 @@ export class FormFilling { domElement.value = value; } - //TODO:4: Investigate and document why we're not using data attributes to store this string in the DOM + //TODO:5: Investigate and document why we're not using data attributes to store this string in the DOM (domElement as any).keeInitialDetectedValue = value; domElement.dispatchEvent( @@ -437,7 +437,7 @@ export class FormFilling { } private initMatchResult(behaviour: FindMatchesBehaviour) { - //TODO:4: #6 create new object might cause issues with multi-page or submit behaviour? if not, this would be neater: + //TODO:5: #6 create new object might cause issues with multi-page or submit behaviour? if not, this would be neater: // matchResult = new MatchResult(); this.matchResult.UUID = ""; this.matchResult.entries = []; @@ -683,7 +683,7 @@ export class FormFilling { offsetParent: true, // This tricks element visibility checks into treating this as visible to the user addEventListener: function () { return; - }, //TODO:4: hook up to the submit function to simulate real form submission + }, //TODO:5: hook up to the submit function to simulate real form submission removeEventListener: function () { return; } @@ -728,7 +728,7 @@ export class FormFilling { // form and entry combination. We could be more efficient for the common case of 1 form // by avoiding the clone then but keeping the same behaviour gives us a higher chance // of noticing bugs. - matchResult.entries[i] = JSON.parse(crString); //TODO:4: faster clone? https://developer.mozilla.org/en-US/docs/Web/Guide/API/DOM/The_structured_clone_algorithm ? + matchResult.entries[i] = JSON.parse(crString); //TODO:5: faster clone? https://developer.mozilla.org/en-US/docs/Web/Guide/API/DOM/The_structured_clone_algorithm ? // Nothing to do if we have no matching entries available. if (matchResult.entries[i].length == 0) continue; @@ -1013,7 +1013,7 @@ export class FormFilling { } if (matchingLogin != null) { - //TODO:4: #6 multi-page + //TODO:5: #6 multi-page // // record / update the info attached to this tab regarding // // the number of pages of forms we want to fill in // // NB: we do this even if we know this is a single form @@ -1034,7 +1034,7 @@ export class FormFilling { // } // // If the user manually requested this to be filled in or the current page is unknown - // if (!automated)//TODO:4: #6 multi-page || tabState.currentPage <= 0) + // if (!automated)//TODO:5: #6 multi-page || tabState.currentPage <= 0) // { // let maximumPageCount = 1; // for (let i = 0; i < matchingLogin.passwords.length; i++) @@ -1049,7 +1049,7 @@ export class FormFilling { // if (otherField.formFieldPage > maximumPageCount) // maximumPageCount = otherField.formFieldPage; // } - // //TODO:4: #6: multi-page + // //TODO:5: #6: multi-page // // // always assume page 1 (very rare cases will go wrong - see github KeeFox #411 for relevant enhancement request) // // // Possible regression since v1.4: We used to ignore currentPage entirely for the first // // // page of a submission, now we might try to give preference to page 1 fields (though total @@ -1142,7 +1142,7 @@ export class FormFilling { // If this form fill is the non-final page of a multi-page login process we record the // UUID and dbFilename. We also enable auto-submit in some circumstances - //TODO:4: #6: multi-page + //TODO:5: #6: multi-page // if (matchResult.UUID != undefined && matchResult.UUID != null && matchResult.UUID != "") // { // if (tabState.currentPage > 0 && tabState.currentPage < tabState.maximumPage) @@ -1415,7 +1415,7 @@ export class FormFilling { candidate.score += distanceFactor * distanceScore; }); - //TODO:4: more accurate searching of submit buttons, etc. to avoid password resets if possible + //TODO:5: more accurate searching of submit buttons, etc. to avoid password resets if possible // maybe special cases for common HTML output patterns (e.g. javascript-only ASP.NET forms) let maxScore = submitElements[0].score; @@ -1435,7 +1435,7 @@ export class FormFilling { semanticWhitelistCache, semanticBlacklistCache ) { - //TODO:4: other languages + //TODO:5: other languages const goodWords = [ "submit", "login", @@ -1580,7 +1580,7 @@ export class FormFilling { form.submit(); } - //TODO:4: maybe something like this might be useful? Dunno why a click() + //TODO:5: maybe something like this might be useful? Dunno why a click() // above wouldn't be sufficient but maybe some custom event raising might be handy... /* function simulateClick() { diff --git a/src/page/formSaving.ts b/src/page/formSaving.ts index 19d1b215..91ca712b 100644 --- a/src/page/formSaving.ts +++ b/src/page/formSaving.ts @@ -18,7 +18,7 @@ export class FormSaving { private Logger: KeeLogger; private formUtils: FormUtils; private SubmitHandlerAttachments: SubmitHandlerAttachment[] = []; - private matchResult: MatchResult; //TODO:4: May be overkill to have all this data available for saving + private matchResult: MatchResult; //TODO:5: May be overkill to have all this data available for saving constructor(private myPort: chrome.runtime.Port, logger: KeeLogger, formUtils: FormUtils) { this.Logger = logger; @@ -53,7 +53,7 @@ export class FormSaving { // This won't always be called before all event handlers on the web page so on // some sites we will store invalid data (in cases where the login scripts // mangle the contents of the fields before submitting them). - //TODO:4: Possibly could slightly reduce incidence of this problem by listening + //TODO:5: Possibly could slightly reduce incidence of this problem by listening // to every click on the document body or tracking all input events but performance? private submitHandler(_e: Event, form: HTMLFormElement) { this.Logger.debug("submitHandler called"); @@ -107,7 +107,7 @@ export class FormSaving { for (let i = 0; i < passwords.length; i++) passwordFields.push(passwords[i]); - //TODO:4: try to distinguish between multi-password login/signup and typo. maybe: if username exists and matches existing password it is a typo, else multi-password + //TODO:5: try to distinguish between multi-password login/signup and typo. maybe: if username exists and matches existing password it is a typo, else multi-password //return; } // it's probably a password change form, but may be a sign-up form else { @@ -123,7 +123,7 @@ export class FormSaving { // if there are only two passwords we already know that they match if (passwords.length == 2) { passwordFields.push(passwords[0]); - //TODO:4: it is also reasonably likely that this indicates a + //TODO:5: it is also reasonably likely that this indicates a // sign-up form rather than a password change form. decide // which here and flag which one it is. for now, we just assume // it's a sign-up form becuase that is more useful for the user in many cases diff --git a/src/page/formsUtils.ts b/src/page/formsUtils.ts index 3d97e19e..6ee15e0f 100644 --- a/src/page/formsUtils.ts +++ b/src/page/formsUtils.ts @@ -188,8 +188,8 @@ export class FormUtils { // Work out which DOM form element is most likely to be the username field. // This information is only used to display the username to the user so an inaccurate // choice won't impact the form detection or filling behaviour. - //TODO:4: Extend this to inspect more than just the name of the field. E.g. max length? - //TODO:4: For form filling (not submitting) we might want to select based upon found data in KeePass? + //TODO:5: Extend this to inspect more than just the name of the field. E.g. max length? + //TODO:5: For form filling (not submitting) we might want to select based upon found data in KeePass? if (firstPossibleUsernameIndex != -1) usernameIndex = firstPossibleUsernameIndex; else if (firstPasswordIndex > 0) usernameIndex = firstPasswordIndex - 1; this.Logger.debug("usernameIndex: " + usernameIndex); diff --git a/src/panels/main.ts b/src/panels/main.ts index 1c7c0346..b781d070 100644 --- a/src/panels/main.ts +++ b/src/panels/main.ts @@ -87,7 +87,7 @@ async function start() { store.$patch(m.initialState); vueApp.mount("#main"); - //TODO:4: Could be done earlier to speed up initial rendering? + //TODO:5: Could be done earlier to speed up initial rendering? Port.postMessage({ action: Action.GetPasswordProfiles }); diff --git a/src/panels/mainLegacy.ts b/src/panels/mainLegacy.ts index dbe3abb2..378bad94 100644 --- a/src/panels/mainLegacy.ts +++ b/src/panels/mainLegacy.ts @@ -16,7 +16,7 @@ function updateFrameState(newState: FrameState) { } function closePanel() { - //TODO:4: Might want more fine-grained closing in future + //TODO:5: Might want more fine-grained closing in future Port.postMessage({ action: Action.CloseAllPanels }); } diff --git a/src/popup/components/Save1stParty.vue b/src/popup/components/Save1stParty.vue index 544cf452..3e650b55 100644 --- a/src/popup/components/Save1stParty.vue +++ b/src/popup/components/Save1stParty.vue @@ -226,7 +226,7 @@ export default { ...originalField, value: change.value }); - //TODO:4: faster deep clone + //TODO:5: faster deep clone const newFields = JSON.parse( JSON.stringify(updatedSaveState.newEntry.fields) ) as Field[]; diff --git a/src/release-notes/update-notes.html b/src/release-notes/update-notes.html index 4dfd0142..54cea57e 100644 --- a/src/release-notes/update-notes.html +++ b/src/release-notes/update-notes.html @@ -4,7 +4,7 @@ - Kee 3.12 + Kee 4.0