iobroker.eos-admin 7.9.98 → 7.9.100

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (57) hide show
  1. package/INSTALL_TEST_V7.9.100.md +11 -0
  2. package/MERGE_UPDATE_README_V7.9.100.md +5 -0
  3. package/NEXOWATT_EOS_BUILD_INFO.json +20 -20
  4. package/PUBLISH_STABLE_V7.9.100.md +15 -0
  5. package/README.md +6 -16
  6. package/README_STABILITY_V7.9.100.md +3 -0
  7. package/RELEASE_ACCEPTANCE_V7.9.100.md +11 -0
  8. package/RELEASE_NOTES_V7.9.100.md +11 -0
  9. package/adminWww/assets/Intro-DkwRiz1n-v84.js +2 -2
  10. package/adminWww/assets/bootstrap-COulQZax-v84.js +2 -2
  11. package/adminWww/css/eos-auto-update.css +4 -0
  12. package/adminWww/css/eos-ems-overview.css +3 -5
  13. package/adminWww/css/nexowatt-native-shell.css +26 -112
  14. package/adminWww/index.html +21 -18
  15. package/adminWww/js/eos-account-management.js +19 -28
  16. package/adminWww/js/eos-assistant.js +1 -1
  17. package/adminWww/js/eos-auto-update.js +78 -0
  18. package/adminWww/js/eos-ems-overview.js +2 -3
  19. package/adminWww/js/eos-release-watch.js +77 -0
  20. package/adminWww/js/eos-role-bootstrap.js +11 -8
  21. package/adminWww/js/eos-role-ui.js +2 -2
  22. package/adminWww/js/nexowatt-native-shell.js +1 -1
  23. package/adminWww/static/js/nexowatt-stable-login.js +3 -3
  24. package/adminWww/static/js/{nexowatt-stable-v98.js → nexowatt-stable-v100.js} +2 -2
  25. package/build/lib/eosAutoUpdate.js +43 -0
  26. package/build/lib/eosPassword.js +62 -0
  27. package/build/lib/eosRequestSecurity.js +31 -0
  28. package/build/lib/web.js +194 -151
  29. package/build/main.js +2 -1
  30. package/io-package.json +7 -11
  31. package/package.json +23 -13
  32. package/src/lib/eosAutoUpdate.ts +320 -0
  33. package/tools/nexowatt-account-management-selftest.cjs +19 -15
  34. package/tools/nexowatt-apply-ems-overview.cjs +2 -4
  35. package/tools/nexowatt-auto-update-selftest.cjs +34 -0
  36. package/tools/nexowatt-cache-update-selftest.cjs +12 -0
  37. package/tools/nexowatt-clean-legacy-runtime.cjs +1 -1
  38. package/tools/nexowatt-ems-overview-selftest.cjs +1 -1
  39. package/tools/nexowatt-login-layout-selftest.cjs +11 -11
  40. package/tools/nexowatt-merge-update-selftest.cjs +1 -1
  41. package/tools/nexowatt-modern-ui-selftest.cjs +2 -2
  42. package/tools/nexowatt-password-write-selftest.cjs +42 -44
  43. package/tools/nexowatt-request-security-selftest.cjs +11 -0
  44. package/tools/nexowatt-runtime-cleanup-selftest.cjs +6 -6
  45. package/tools/nexowatt-stable-v100-selftest.cjs +27 -0
  46. package/tools/nexowatt-sync-release-version.cjs +1 -42
  47. package/tools/nexowatt-ui-overview-runtime-selftest.cjs +3 -1
  48. package/tools/nexowatt-validate-package.cjs +23 -23
  49. package/tools/nexowatt-version-sync-selftest.cjs +1 -18
  50. package/INSTALL_TEST_V7.9.98.md +0 -39
  51. package/MERGE_UPDATE_README_V7.9.98.md +0 -29
  52. package/PUBLISH_STABLE_V7.9.98.md +0 -33
  53. package/README_STABILITY_V7.9.98.md +0 -22
  54. package/RELEASE_ACCEPTANCE_V7.9.98.md +0 -48
  55. package/RELEASE_NOTES_V7.9.98.md +0 -32
  56. package/tools/nexowatt-account-password-flow-selftest.cjs +0 -186
  57. package/tools/nexowatt-stable-v98-selftest.cjs +0 -14
@@ -1,48 +1,46 @@
1
1
  #!/usr/bin/env node
2
2
  'use strict';
3
- const assert = require('node:assert/strict');
4
- const fs = require('node:fs');
5
- const path = require('node:path');
6
- const vm = require('node:vm');
7
- const root = path.resolve(__dirname, '..');
8
- const built = fs.readFileSync(path.join(root, 'build/lib/web.js'), 'utf8');
9
- const source = fs.readFileSync(path.join(root, 'src/lib/web.ts'), 'utf8');
10
- const begin = built.indexOf(' getEosPasswordUserName(userId) {');
11
- const end = built.indexOf(' async destroyEosRequestSessions', begin);
12
- assert(begin >= 0 && end > begin, 'password methods not found in built backend');
13
- const methods = built.slice(begin, end);
14
- const sandbox = { module: { exports: null }, EOS_PASSWORD_SERVICE_USER: 'system.user.admin' };
15
- vm.runInNewContext(`module.exports = class Harness {\nconstructor(adapter){this.adapter=adapter;}\n${methods}\n}`, sandbox);
16
- const Harness = sandbox.module.exports;
17
- (async () => {
18
- const calls = [];
19
- const userObject = { _id: 'system.user.user', common: { password: '$2b$hash' }, native: { keep: true } };
20
- const adapter = {
21
- setPasswordAsync: async (user, password, options) => calls.push(['set', user, password, options]),
22
- checkPasswordAsync: async (user, password, options) => { calls.push(['check', user, password, options]); return [true, `system.user.${user}`]; },
23
- getForeignObjectAsync: async id => { calls.push(['get', id]); return JSON.parse(JSON.stringify(userObject)); },
24
- extendForeignObjectAsync: async (id, patch, options) => calls.push(['extend', id, patch, options]),
25
- setForeignObjectAsync: async () => { throw new Error('full user object replacement must not be used'); },
3
+ const assert=require('node:assert/strict');
4
+ const fs=require('node:fs');
5
+ const path=require('node:path');
6
+ const {normalizeEosPasswordTarget,setEosUserPasswordWithVerification}=require('../build/lib/eosPassword.js');
7
+ const root=path.resolve(__dirname,'..');
8
+ const source=fs.readFileSync(path.join(root,'src/lib/eosPassword.ts'),'utf8');
9
+ const web=fs.readFileSync(path.join(root,'src/lib/web.ts'),'utf8');
10
+
11
+ function adapterFixture({verify=true,persist=true,callback=false}={}){
12
+ let password='old';
13
+ let hash=persist?'$old':'';
14
+ const calls=[];
15
+ const adapter={
16
+ calls,
17
+ getForeignObjectAsync:async id=>id==='system.user.user'?{_id:id,common:{password:hash},native:{}}:null,
18
+ checkPasswordAsync:async (user,value,options)=>{calls.push({kind:'check',user,value,options});return [verify&&user==='user'&&value===password,'system.user.user'];},
26
19
  };
27
- const harness = new Harness(adapter);
28
- await harness.setEosUserPassword('system.user.user', 'NexoWatt2025!');
29
- assert.deepEqual(calls[0].slice(0, 3), ['set', 'user', 'NexoWatt2025!']);
30
- assert.deepEqual(calls[1].slice(0, 3), ['check', 'user', 'NexoWatt2025!']);
31
- await harness.updateEosAccountMetadata('system.user.user', (native, account) => {
32
- account.passwordInitialized = true;
33
- native.nexowattPasswordChangeRequired = false;
34
- });
35
- const extend = calls.find(row => row[0] === 'extend');
36
- assert(extend, 'native metadata was not extended');
37
- assert.equal(extend[1], 'system.user.user');
38
- assert.equal(extend[2].native.keep, true);
39
- assert.equal(extend[2].native.nexowattEosAccount.passwordInitialized, true);
40
- assert(!Object.prototype.hasOwnProperty.call(extend[2], 'common'), 'password/common must not be overwritten by metadata update');
41
- for (const code of [source, built]) {
42
- assert.match(code, /setPasswordAsync\(userName, password/);
43
- assert.match(code, /checkPasswordAsync\(userName, password/);
44
- assert.match(code, /extendForeignObjectAsync/);
45
- assert.match(code, /passwordVerificationFailed/);
20
+ const set=async(user,value,options)=>{calls.push({kind:'set',user,value,options});if(user!=='user')throw new Error('shortUserNameRequired');if(persist){password=value;hash=`$hash:${value}`;}};
21
+ if(callback) adapter.setPassword=(user,value,options,cb)=>set(user,value,options).then(()=>cb(),cb);
22
+ else adapter.setPasswordAsync=set;
23
+ return adapter;
24
+ }
25
+
26
+ (async()=>{
27
+ assert.deepEqual(normalizeEosPasswordTarget('user'),{userId:'system.user.user',userName:'user'});
28
+ assert.deepEqual(normalizeEosPasswordTarget('system.user.user'),{userId:'system.user.user',userName:'user'});
29
+ assert.throws(()=>normalizeEosPasswordTarget('system.user.bad.name'),/invalidPasswordTarget/);
30
+ for(const fixture of [adapterFixture(),adapterFixture({callback:true})]){
31
+ const result=await setEosUserPasswordWithVerification(fixture,'system.user.user','Strong!2026');
32
+ assert.equal(result.userName,'user');
33
+ assert.equal(fixture.calls.find(c=>c.kind==='set').user,'user','password API must receive short user name');
34
+ assert.deepEqual(fixture.calls.find(c=>c.kind==='set').options,{user:'system.user.admin'});
35
+ assert.equal(fixture.calls.find(c=>c.kind==='check').user,'user','password check must receive short user name');
46
36
  }
47
- console.log('[NexoWatt EOS password write] OK: real account name, verified password API and metadata-only update');
48
- })().catch(error => { console.error(error.stack || error); process.exit(1); });
37
+ const noCheck=adapterFixture();delete noCheck.checkPasswordAsync;
38
+ await setEosUserPasswordWithVerification(noCheck,'user','NoCheck!2026');
39
+ await assert.rejects(()=>setEosUserPasswordWithVerification(adapterFixture({persist:false}),'user','Missing!2026'),/passwordNotPersisted/);
40
+ await assert.rejects(()=>setEosUserPasswordWithVerification(adapterFixture({verify:false}),'user','Verify!2026'),/passwordVerificationFailed/);
41
+ for(const marker of ['setPasswordAsync(userName','checkPasswordAsync(userName','common?.password','userId.replace(/^system\\.user\\./']) assert(source.includes(marker),`source marker missing: ${marker}`);
42
+ assert(!/setForeignObject|common\.password\s*=/.test(source),'helper must never hash/write common.password itself');
43
+ assert(web.includes('extendForeignObjectAsync')&&web.includes('passwordMetadataNotPersisted'),'first-login metadata persistence guard missing');
44
+ assert(!web.includes('setForeignObjectAsync(access.userId, userObject)'),'stale full-user first-login write remains');
45
+ console.log('[NexoWatt EOS password write] OK (short name, persistence, credential and native-only metadata)');
46
+ })().catch(error=>{console.error(error?.stack||error);process.exit(1);});
@@ -0,0 +1,11 @@
1
+ #!/usr/bin/env node
2
+ 'use strict';
3
+ const assert=require('node:assert/strict');
4
+ const {isEosSameOriginRequest}=require('../build/lib/eosRequestSecurity.js');
5
+ assert.equal(isEosSameOriginRequest({host:'192.168.10.124:8081'}),true);
6
+ assert.equal(isEosSameOriginRequest({origin:'http://192.168.10.124:8081',host:'192.168.10.124:8081','sec-fetch-site':'same-origin'}),true);
7
+ assert.equal(isEosSameOriginRequest({origin:'https://eos.example.test',host:'proxy:443','x-forwarded-host':'eos.example.test','sec-fetch-site':'same-site'}),true);
8
+ assert.equal(isEosSameOriginRequest({origin:'http://192.168.10.125:8081',host:'192.168.10.124:8081','sec-fetch-site':'same-origin'}),false);
9
+ assert.equal(isEosSameOriginRequest({origin:'http://192.168.10.124:8081',host:'192.168.10.124:8081','sec-fetch-site':'cross-site'}),false);
10
+ assert.equal(isEosSameOriginRequest({origin:'file:///tmp/eos',host:'192.168.10.124:8081'}),false);
11
+ console.log('[NexoWatt EOS request security] OK (LAN, proxy and cross-site guard)');
@@ -15,15 +15,15 @@ try {
15
15
  fs.mkdirSync(path.join(temp, 'src-admin', 'public', 'js'), { recursive: true });
16
16
  fs.mkdirSync(path.join(temp, 'src-admin', 'public', 'static', 'js'), { recursive: true });
17
17
  fs.mkdirSync(path.join(temp, 'adminWww', 'static', 'js'), { recursive: true });
18
- fs.writeFileSync(path.join(temp, 'NEXOWATT_EOS_BUILD_INFO.json'), JSON.stringify({ runtimeEntry: 'v82', shellCacheVersion: 98 }));
18
+ fs.writeFileSync(path.join(temp, 'NEXOWATT_EOS_BUILD_INFO.json'), JSON.stringify({ runtimeEntry: 'v82', shellCacheVersion: 100 }));
19
19
 
20
20
  const keep = [
21
21
  'adminWww/assets/bootstrap-current-v82.js',
22
22
  'adminWww/assets/Objects-current-v82.js',
23
23
  'adminWww/remoteEntry-v82.js',
24
24
  'adminWww/remoteEntry.js',
25
- 'adminWww/static/js/nexowatt-stable-v98.js',
26
- 'src-admin/public/static/js/nexowatt-stable-v98.js',
25
+ 'adminWww/static/js/nexowatt-stable-v100.js',
26
+ 'src-admin/public/static/js/nexowatt-stable-v100.js',
27
27
  'adminWww/static/js/nexowatt-stable-login.js',
28
28
  ];
29
29
  const remove = [
@@ -34,8 +34,8 @@ try {
34
34
  'adminWww/js/eos-branding.js',
35
35
  'adminWww/css/eos-branding.css',
36
36
  'src-admin/public/js/eos-security-ui.js',
37
- 'adminWww/static/js/nexowatt-stable-v97.js',
38
- 'src-admin/public/static/js/nexowatt-stable-v95.js',
37
+ 'adminWww/static/js/nexowatt-stable-v98.js',
38
+ 'src-admin/public/static/js/nexowatt-stable-v97.js',
39
39
  ];
40
40
  for (const rel of [...keep, ...remove]) {
41
41
  const file = path.join(temp, rel);
@@ -45,7 +45,7 @@ try {
45
45
 
46
46
  const result = cleanLegacyRuntime({ root: temp, quiet: true, silent: true });
47
47
  assert.strictEqual(result.activeRuntime, 82);
48
- assert.strictEqual(result.activeShell, 98);
48
+ assert.strictEqual(result.activeShell, 100);
49
49
  assert.strictEqual(result.removed.length, remove.length);
50
50
  for (const rel of keep) assert.ok(fs.existsSync(path.join(temp, rel)), `current runtime removed: ${rel}`);
51
51
  for (const rel of remove) assert.ok(!fs.existsSync(path.join(temp, rel)), `legacy file remained: ${rel}`);
@@ -0,0 +1,27 @@
1
+ #!/usr/bin/env node
2
+ 'use strict';
3
+ const fs=require('node:fs'),path=require('node:path');
4
+ const root=path.resolve(__dirname,'..');
5
+ const read=r=>fs.readFileSync(path.join(root,r),'utf8');
6
+ const must=(c,m)=>{if(!c){console.error(`[NexoWatt EOS stable v100] ${m}`);process.exit(1)}};
7
+ const pkg=JSON.parse(read('package.json'));
8
+ const io=JSON.parse(read('io-package.json'));
9
+ const info=JSON.parse(read('NEXOWATT_EOS_BUILD_INFO.json'));
10
+ const source=read('src/lib/eosAutoUpdate.ts');
11
+ const built=read('build/lib/eosAutoUpdate.js');
12
+ const web=read('src/lib/web.ts');
13
+ const webBuilt=read('build/lib/web.js');
14
+ const ui=read('adminWww/js/eos-auto-update.js');
15
+ const index=read('adminWww/index.html');
16
+ must(pkg.version==='7.9.100'&&io.version==='7.9.100'&&io.common.version==='7.9.100'&&info.version==='7.9.100','version drift');
17
+ must(io.native.eosNexoWattAutoUpdate===true,'auto update is not enabled by default');
18
+ for(const marker of ['adapterAutoUpgrade','automaticUpgrade','isNexoWattRepositoryEntry','previousPolicies','previousRepositoryEnabled','getRepository']){
19
+ must(source.includes(marker)&&built.includes(marker),`manager marker missing: ${marker}`);
20
+ }
21
+ must(source.includes("const POLICY: NexoWattAutoUpdatePolicy = 'major'")&&built.includes("const POLICY = 'major'"),'manager major policy marker missing');
22
+ must(source.includes("auto.defaultPolicy = 'none'")&&source.includes('stableVersion'),'non-NexoWatt/stable isolation missing');
23
+ must(web.includes('/nexowatt/updates/status')&&web.includes('/nexowatt/updates/settings')&&webBuilt.includes('/nexowatt/updates/settings'),'update API missing');
24
+ must(ui.includes('Automatische Adapter-Updates')&&ui.includes('X-NexoWatt-EOS-Auto-Update')&&ui.includes('jederzeit änderbar'),'admin toggle missing');
25
+ must(index.includes('eos-auto-update.css?v=100')&&index.includes('eos-auto-update.js?v=100')&&index.includes('nexowatt-stable-v100.js?v=100'),'v100 assets missing');
26
+ must(!index.includes('?v=99')&&!index.includes('stable-v99'),'stale v99 browser assets active');
27
+ console.log('[NexoWatt EOS stable v100] OK');
@@ -19,14 +19,6 @@ function setValue(changes, label, object, key, value) {
19
19
  }
20
20
  }
21
21
 
22
- function setJsonValue(changes, label, object, key, value) {
23
- const previous = object[key];
24
- if (JSON.stringify(previous) !== JSON.stringify(value)) {
25
- changes.push({ label, previous, value });
26
- object[key] = value === undefined ? undefined : JSON.parse(JSON.stringify(value));
27
- }
28
- }
29
-
30
22
  function syncReleaseVersion(rootDir) {
31
23
  const root = path.resolve(rootDir);
32
24
  const packageFile = path.join(root, 'package.json');
@@ -70,40 +62,7 @@ function syncReleaseVersion(rootDir) {
70
62
  update(json) {
71
63
  setValue(changes, 'package-lock.json version', json, 'version', version);
72
64
  if (json.packages?.['']) {
73
- const rootPackage = json.packages[''];
74
- setValue(changes, 'package-lock.json packages[""] version', rootPackage, 'version', version);
75
- // A merge archive can update package.json while leaving stale release scripts,
76
- // files and policy metadata in package-lock.json. npm reads the lock root during
77
- // packaging, so keep every release-critical root field canonical as well.
78
- for (const key of [
79
- 'name',
80
- 'description',
81
- 'license',
82
- 'author',
83
- 'private',
84
- 'engines',
85
- 'main',
86
- 'files',
87
- 'scripts',
88
- 'dependencies',
89
- 'devDependencies',
90
- 'overrides',
91
- 'keywords',
92
- 'publishConfig',
93
- 'nexowattReleasePolicy',
94
- 'publisher',
95
- 'copyright',
96
- ]) {
97
- if (Object.prototype.hasOwnProperty.call(pkg, key)) {
98
- setJsonValue(
99
- changes,
100
- `package-lock.json packages[""] ${key}`,
101
- rootPackage,
102
- key,
103
- pkg[key],
104
- );
105
- }
106
- }
65
+ setValue(changes, 'package-lock.json packages[""] version', json.packages[''], 'version', version);
107
66
  }
108
67
  },
109
68
  },
@@ -5,7 +5,9 @@ const runtime=read('adminWww/js/eos-ems-overview.js');const source=read('src-adm
5
5
  if(runtime!==source)fail('runtime source/build drift');
6
6
  for(const marker of ['nexowatt-ems-overview-v1','nexowatt-ui.*.info.adminOverview.*','system.adapter.nexowatt-ui.*.alive','POLL_MS = 5000','STALE_MS = 20000',"REQUIRED_UI_VERSION = '0.8.198'",'getForeignStates','Keine Kachel besitzt Schreibhoheit','currentDecisions','§14a-Fallback','nexowatt-eos-admin-socket-ready','readUiAdapterInfo','socketFromReact'])if(!runtime.includes(marker))fail(`runtime marker missing: ${marker}`);
7
7
  for(const forbidden of ['setForeignState','setState(','sendToHost','writeFile','extendObject'])if(runtime.includes(forbidden))fail(`read-only runtime contains ${forbidden}`);
8
- for(const marker of ['eos-ems-overview.css?v=98','eos-ems-overview.js?v=98','nexowatt-stable-v98.js?v=98'])if(!index.includes(marker))fail(`index marker missing: ${marker}`);
8
+ for(const marker of ['eos-ems-overview.css?v=100','eos-ems-overview.js?v=100','nexowatt-stable-v100.js?v=100','eos-release-watch.js?v=100'])if(!index.includes(marker))fail(`index marker missing: ${marker}`);
9
+ if(runtime.includes('Vollständige EMS-Diagnose öffnen'))fail('unsupported EMS destination remains visible');
10
+ if(!intro.includes('eos-overview-edit-controls')||!introBundle.includes('eos-overview-edit-controls'))fail('edit control is not inside bottom card grid');
9
11
  if(!css.includes('#eos-ems-overview-runtime')||!css.includes('.eos-ems-overview-metrics')||!css.includes('startup and compatibility messages stay compact'))fail('EMS card CSS incomplete');
10
12
  if(role.includes('overview.innerHTML = `')||!role.includes('never cover the real Admin Intro'))fail('obsolete role overview still active');
11
13
  if(!shell.includes("label: 'Installateur'")||!shell.includes("label: 'Endkunde'")||!shell.includes('eosNativeReactOverview'))fail('native overview role bridge incomplete');
@@ -41,23 +41,20 @@ if (pkg.scripts['test:eos-version-sync'] !== 'node tools/nexowatt-version-sync-s
41
41
  if (pkg.scripts['verify:eos-merge'] !== 'node tools/nexowatt-merge-update-selftest.cjs') fail('merge update selftest script is missing or incorrect');
42
42
  if (!pkg.scripts['check:eos-stability']?.includes('nexowatt-version-sync-selftest.cjs')) fail('version sync selftest is not part of check:eos-stability');
43
43
  if (!pkg.scripts['check:eos-stability']?.includes('nexowatt-merge-update-selftest.cjs')) fail('merge update selftest is not part of check:eos-stability');
44
- if (pkg.scripts['check:eos-stable-v98'] !== 'node tools/nexowatt-stable-v98-selftest.cjs') fail('stable v98 selftest script is missing or incorrect');
44
+ if (pkg.scripts['check:eos-stable-v100'] !== 'node tools/nexowatt-stable-v100-selftest.cjs') fail('stable v100 selftest script is missing or incorrect');
45
+ if (pkg.scripts['test:eos-password-write'] !== 'node tools/nexowatt-password-write-selftest.cjs') fail('password write selftest script is missing');
46
+ if (pkg.scripts['test:eos-request-security'] !== 'node tools/nexowatt-request-security-selftest.cjs') fail('request security selftest script is missing');
47
+ if (pkg.scripts['test:eos-cache-update'] !== 'node tools/nexowatt-cache-update-selftest.cjs') fail('cache update selftest script is missing');
48
+ for (const marker of ['nexowatt-password-write-selftest.cjs','nexowatt-request-security-selftest.cjs','nexowatt-cache-update-selftest.cjs']) if (!pkg.scripts['check:eos-stability']?.includes(marker)) fail(`stability check must execute ${marker}`);
45
49
  if (!pkg.scripts.prepublishOnly?.startsWith('npm run sync:eos-version && npm run prepare:eos-release-defaults && npm run check:eos-publish-channel')) fail('prepublishOnly must synchronize versions and normalize release defaults before the publish channel guard');
46
50
  if (pkg.scripts['precheck:eos-package'] !== 'npm run sync:eos-version && npm run prepare:eos-release-defaults && npm run clean:eos-runtime') fail('precheck:eos-package must synchronize versions, normalize release defaults and clean stale runtime files');
47
51
  if (pkg.scripts['precheck:eos-stability'] !== 'npm run sync:eos-version && npm run prepare:eos-release-defaults && npm run clean:eos-runtime') fail('precheck:eos-stability must synchronize versions, normalize release defaults and clean stale runtime files');
48
52
  if (pkg.scripts['test:eos-publish-channel'] !== 'node tools/nexowatt-publish-channel-selftest.cjs') fail('publish channel selftest script is missing');
49
53
  if (!pkg.scripts['check:eos-stability']?.includes('nexowatt-publish-channel-selftest.cjs')) fail('stability check must execute the publish channel selftest');
50
54
  if (!pkg.scripts['check:eos-stability']?.includes('nexowatt-release-defaults-selftest.cjs')) fail('stability check must execute the release-default selftest');
51
- if (!pkg.scripts['check:eos-stability']?.includes('nexowatt-password-write-selftest.cjs')) fail('password-write selftest is not part of check:eos-stability');
52
- if (!pkg.scripts['check:eos-stability']?.includes('nexowatt-account-password-flow-selftest.cjs')) fail('account-password flow selftest is not part of check:eos-stability');
53
55
  if (io.native?.auth !== true) fail('fresh sales installations must default to authenticated access');
54
56
  if (io.native?.eosHideLegacyBackupFromNonAdmins !== true) fail('internal BackItUp reserve must default to Admin/Service visibility');
55
57
  if (io.native?.nexowattHideLegacyBackupFromNonAdmins !== true) fail('NexoWatt backup visibility compatibility flag must default to true');
56
- for (const key of ['description', 'files', 'scripts', 'nexowattReleasePolicy']) {
57
- if (JSON.stringify(pkgLock.packages?.['']?.[key]) !== JSON.stringify(pkg[key])) {
58
- fail(`package-lock root ${key} must match package.json`);
59
- }
60
- }
61
58
  for (const [label, value] of [
62
59
  ['io-package common.version', io.common?.version],
63
60
  ['io-package top-level version', io.version],
@@ -107,6 +104,7 @@ for (const file of [
107
104
  'adminWww/js/eos-basic-settings.js',
108
105
  'adminWww/js/eos-role-ui.js',
109
106
  'adminWww/js/eos-account-management.js',
107
+ 'adminWww/js/eos-release-watch.js',
110
108
  'adminWww/js/eos-assistant.js',
111
109
  'adminWww/css/nexowatt-native-shell.css',
112
110
  'adminWww/img/eos/nexowatt-192.png',
@@ -117,14 +115,14 @@ for (const file of [
117
115
  'LICENSE',
118
116
  'NEXOWATT_PROPRIETARY_LICENSE.md',
119
117
  'THIRD_PARTY_NOTICES.md',
120
- 'README_STABILITY_V7.9.98.md',
121
- 'RELEASE_NOTES_V7.9.98.md',
122
- 'PUBLISH_STABLE_V7.9.98.md',
123
- 'INSTALL_TEST_V7.9.98.md',
124
- 'RELEASE_ACCEPTANCE_V7.9.98.md',
118
+ 'README_STABILITY_V7.9.100.md',
119
+ 'RELEASE_NOTES_V7.9.100.md',
120
+ 'PUBLISH_STABLE_V7.9.100.md',
121
+ 'INSTALL_TEST_V7.9.100.md',
122
+ 'RELEASE_ACCEPTANCE_V7.9.100.md',
125
123
  'MERGE_UPDATE.ps1',
126
124
  'MERGE_UPDATE.cmd',
127
- 'MERGE_UPDATE_README_V7.9.98.md',
125
+ 'MERGE_UPDATE_README_V7.9.100.md',
128
126
  'tools/nexowatt-patch-built-frontend.cjs',
129
127
  'tools/nexowatt-native-shell-selftest.cjs',
130
128
  'tools/nexowatt-clean-legacy-runtime.cjs',
@@ -135,6 +133,9 @@ for (const file of [
135
133
  'tools/nexowatt-role-access-selftest.cjs',
136
134
  'tools/nexowatt-first-login-selftest.cjs',
137
135
  'tools/nexowatt-account-management-selftest.cjs',
136
+ 'tools/nexowatt-password-write-selftest.cjs',
137
+ 'tools/nexowatt-request-security-selftest.cjs',
138
+ 'tools/nexowatt-cache-update-selftest.cjs',
138
139
  'tools/nexowatt-modern-ui-selftest.cjs',
139
140
  'tools/nexowatt-login-layout-selftest.cjs',
140
141
  'tools/nexowatt-internal-reserve-selftest.cjs',
@@ -142,14 +143,12 @@ for (const file of [
142
143
  'tools/nexowatt-sync-release-version.cjs',
143
144
  'tools/nexowatt-version-sync-selftest.cjs',
144
145
  'tools/nexowatt-merge-update-selftest.cjs',
145
- 'tools/nexowatt-stable-v98-selftest.cjs',
146
- 'tools/nexowatt-password-write-selftest.cjs',
147
- 'tools/nexowatt-account-password-flow-selftest.cjs',
146
+ 'tools/nexowatt-stable-v100-selftest.cjs',
148
147
  'tools/nexowatt-ems-overview-selftest.cjs',
149
148
  'tools/nexowatt-ui-overview-runtime-selftest.cjs',
150
149
  'adminWww/js/eos-ems-overview.js',
151
150
  'adminWww/css/eos-ems-overview.css',
152
- 'adminWww/static/js/nexowatt-stable-v98.js',
151
+ 'adminWww/static/js/nexowatt-stable-v100.js',
153
152
  'src-admin/src/components/Intro/NexoWattEmsOverview.tsx',
154
153
  'tools/nexowatt-publish-channel-guard.cjs',
155
154
  'tools/nexowatt-publish-channel-selftest.cjs',
@@ -177,8 +176,8 @@ const shellTag = String(buildInfo.shellCacheTag || shellCache);
177
176
  if (!runtime || !Number.isFinite(runtimeNumber)) fail(`invalid runtimeEntry ${runtime}`);
178
177
  if (!Number.isFinite(shellCache)) fail(`invalid shellCacheVersion ${buildInfo.shellCacheVersion}`);
179
178
  for (const marker of [
180
- `hostInit-${runtime}.js?v=${runtimeNumber}`,
181
- `index-CQZugZ1z-${runtime}.js?v=${runtimeNumber}`,
179
+ `hostInit-${runtime}.js?v=${shellTag}`,
180
+ `index-CQZugZ1z-${runtime}.js?v=${shellTag}`,
182
181
  `eos-manual-write-policy.js?v=${shellTag}`,
183
182
  `nexowatt-native-shell.css?v=${shellTag}`,
184
183
  `nexowatt-native-shell.js?v=${shellTag}`,
@@ -192,8 +191,9 @@ if (!index.includes(`eos-account-management.js?v=${shellTag}`)) fail('account ma
192
191
  if (!index.includes(`eos-assistant.js?v=${shellTag}`)) fail('EOS Assist cache key mismatch');
193
192
  if (!index.includes(`eos-ems-overview.js?v=${shellTag}`)) fail('EMS overview cache key mismatch');
194
193
  if (!index.includes(`eos-ems-overview.css?v=${shellTag}`)) fail('EMS overview CSS cache key mismatch');
195
- if (!index.includes(`nexowatt-stable-v98.js?v=${shellTag}`)) fail('stable v98 cache key mismatch');
196
- if (index.indexOf(`eos-manual-write-policy.js?v=${shellTag}`) > index.indexOf(`hostInit-${runtime}.js?v=${runtimeNumber}`)) fail('manual-write policy must load before the React runtime');
194
+ if (!index.includes(`nexowatt-stable-v100.js?v=${shellTag}`)) fail('stable v100 cache key mismatch');
195
+ if (!index.includes(`eos-release-watch.js?v=${shellTag}`)) fail('release watcher cache key mismatch');
196
+ if (index.indexOf(`eos-manual-write-policy.js?v=${shellTag}`) > index.indexOf(`hostInit-${runtime}.js?v=${shellTag}`)) fail('manual-write policy must load before the React runtime');
197
197
  if (!index.includes('class="eos-native-shell"')) fail('native NexoWatt shell class missing');
198
198
  for (const legacy of ['eos-branding.js', 'eos-security-ui.js', 'eos-console-quiet.js', 'eos-objects-state-tools.js']) {
199
199
  if (index.includes(legacy)) fail(`legacy browser overlay still loaded: ${legacy}`);
@@ -241,7 +241,7 @@ if (accountManagement.includes("launcher.className = 'eos-account-management-lau
241
241
  if (accountManagement.includes('new MutationObserver')) fail('account-management runtime adds a second broad DOM observer');
242
242
  if (read('src-admin/public/js/eos-account-management.js') !== accountManagement) fail('account-management source/build drift');
243
243
  const roleBootstrap = read('adminWww/js/eos-role-bootstrap.js');
244
- if (!roleBootstrap.includes('installIntegratedFirstLogin') || !roleBootstrap.includes('v98 compact normal-login first activation')) fail('compact integrated first-login is incomplete');
244
+ if (!roleBootstrap.includes('installIntegratedFirstLogin') || !roleBootstrap.includes('v100 normal-login first activation')) fail('compact integrated first-login is incomplete');
245
245
  if (/data-eos-account=|selector\.innerHTML/.test(roleBootstrap)) fail('login role buttons must not enlarge the normal login card');
246
246
  if (!roleBootstrap.includes('nexowatt/account/passwordless-status') || !roleBootstrap.includes('eligibility.allowed')) fail('server-checked first-login eligibility is incomplete');
247
247
  if (roleBootstrap.includes('installPasswordlessFirstLoginLauncher')) fail('old first-login launcher remains active');
@@ -24,19 +24,7 @@ try {
24
24
  const currentPkg = JSON.parse(fs.readFileSync(path.join(root, 'package.json'), 'utf8'));
25
25
  const version = currentPkg.version;
26
26
  writeJson('package.json', currentPkg);
27
- writeJson('package-lock.json', {
28
- name: currentPkg.name,
29
- version: '7.9.92',
30
- packages: {
31
- '': {
32
- version: '7.9.92',
33
- description: 'stale description',
34
- files: ['README_STABILITY_V7.9.92.md'],
35
- scripts: { 'check:eos-stable-v92': 'node stale.js' },
36
- nexowattReleasePolicy: { distTag: 'latest', purpose: 'stale 7.9.92 policy' },
37
- },
38
- },
39
- });
27
+ writeJson('package-lock.json', { name: currentPkg.name, version: '7.9.92', packages: { '': { version: '7.9.92' } } });
40
28
  writeJson('io-package.json', {
41
29
  version: '7.9.92',
42
30
  common: {
@@ -87,11 +75,6 @@ try {
87
75
  ]) {
88
76
  if (actual !== version) fail(`${label} was not synchronized: ${actual}`);
89
77
  }
90
- for (const key of ['description', 'files', 'scripts', 'nexowattReleasePolicy']) {
91
- if (JSON.stringify(lock.packages[''][key]) !== JSON.stringify(currentPkg[key])) {
92
- fail(`package-lock root ${key} was not synchronized`);
93
- }
94
- }
95
78
  if (io.common.meta !== `${expectedBase}/io-package.json`) fail('io-package URL was not synchronized');
96
79
  if (entry.meta !== `${expectedBase}/io-package.json`) fail('repository entry URL was not synchronized');
97
80
  if (!fs.existsSync(path.join(temp, build.repositoryEntry))) fail('current repository entry was not created');
@@ -1,39 +0,0 @@
1
- # Installationstest – NexoWatt EOS Admin 7.9.98
2
-
3
- ## Installation nach der npm-Veröffentlichung
4
-
5
- ```bash
6
- cd /opt/iobroker
7
- iobroker stop eos-admin.0
8
- npm install --no-save --omit=dev iobroker.eos-admin@7.9.98
9
- iobroker upload eos-admin
10
- iobroker restart eos-admin.0
11
- iobroker restart nexowatt-ui.0
12
- ```
13
-
14
- Version prüfen:
15
-
16
- ```bash
17
- node -p "require('/opt/iobroker/node_modules/iobroker.eos-admin/package.json').version"
18
- ```
19
-
20
- Erwartet:
21
-
22
- ```text
23
- 7.9.98
24
- ```
25
-
26
- Danach im Browser eine vollständige Aktualisierung mit `Strg + F5` durchführen.
27
-
28
- ## Installation des geprüften TGZ ohne Registry
29
-
30
- ```bash
31
- cd /opt/iobroker
32
- iobroker stop eos-admin.0
33
- npm install --no-save --omit=dev /PFAD/iobroker.eos-admin-7.9.98.tgz
34
- iobroker upload eos-admin
35
- iobroker restart eos-admin.0
36
- iobroker restart nexowatt-ui.0
37
- ```
38
-
39
- Anschließend die vollständige Abnahme aus `RELEASE_ACCEPTANCE_V7.9.98.md` durchführen.
@@ -1,29 +0,0 @@
1
- # NexoWatt EOS Admin 7.9.98 – Merge-Update
2
-
3
- Die Datei `NexoWatt_EOS_Admin_7.9.98_STABLE_MERGE_FLAT.zip` ist absichtlich flach aufgebaut. `package.json`, `io-package.json`, `src-admin`, `adminWww`, `build` und alle übrigen Repository-Dateien liegen direkt auf der ersten ZIP-Ebene.
4
-
5
- ## Anwendung auf einem vorhandenen Windows-Arbeitsordner
6
-
7
- 1. Den bestehenden Repository-Ordner sichern oder committen.
8
- 2. Die flache Merge-ZIP direkt in den vorhandenen Ordner entpacken.
9
- 3. Bei der Windows-Abfrage **„Dateien im Ziel ersetzen“** wählen.
10
- 4. Anschließend im Repository ausführen:
11
-
12
- ```powershell
13
- .\MERGE_UPDATE.cmd
14
- ```
15
-
16
- Alternativ:
17
-
18
- ```powershell
19
- .\MERGE_UPDATE.ps1
20
- ```
21
-
22
- Das Merge-Skript:
23
-
24
- - synchronisiert alle Release-Versionen auf `7.9.98`;
25
- - entfernt alte Stable-Laufzeitdateien wie v97;
26
- - prüft Paketstruktur, Stabilität, Rollen, Login, Passwortablauf und EMS-Übersicht;
27
- - führt abschließend einen npm-Pack-Dry-Run aus.
28
-
29
- Erst nach der grünen Abschlussmeldung veröffentlichen. `.git`, lokale Commit-Historie und `node_modules` werden vom Merge-Skript nicht gelöscht.
@@ -1,33 +0,0 @@
1
- # NexoWatt EOS Admin 7.9.98 veröffentlichen
2
-
3
- ## Empfohlener Weg: geprüftes TGZ veröffentlichen
4
-
5
- Dadurch können keine alten oder lokal zusätzlich vorhandenen Dateien in das npm-Paket gelangen.
6
-
7
- ```powershell
8
- npm login
9
- npm whoami
10
- npm publish .\iobroker.eos-admin-7.9.98.tgz --dry-run --tag latest
11
- npm publish .\iobroker.eos-admin-7.9.98.tgz --tag latest
12
- ```
13
-
14
- Der Dry-Run muss mit folgendem Paket enden:
15
-
16
- ```text
17
- + iobroker.eos-admin@7.9.98
18
- ```
19
-
20
- ## Veröffentlichung direkt aus dem Repository
21
-
22
- Nur aus einem sauberen Arbeitsordner ausführen:
23
-
24
- ```powershell
25
- npm login
26
- npm whoami
27
- npm run sync:eos-version
28
- npm run check:eos-release
29
- npm publish --dry-run --tag latest
30
- npm publish --tag latest
31
- ```
32
-
33
- Bei einem Fehler nicht veröffentlichen. Insbesondere müssen `package.json`, `package-lock.json`, `io-package.json`, `src-admin/package.json` und `src-admin/src/version.json` dieselbe Version enthalten.
@@ -1,22 +0,0 @@
1
- # NexoWatt EOS Admin 7.9.98 – Stable-Verkaufskandidat
2
-
3
- Version 7.9.98 beseitigt die vier zuletzt auf dem realen EOS-Testsystem festgestellten Verkaufsblocker, ohne die funktionierende EMS-Live-Diagnose oder die bestehenden Rollenrechte zu erweitern.
4
-
5
- ## Korrigierte Bereiche
6
-
7
- - **Cockpit vollständig bedienbar:** Der Kopf- und Navigationsbereich bleibt stehen; ausschließlich der Inhaltsbereich der Übersicht erhält einen vertikalen Scrollbereich. Dadurch sind auch lange EMS-Ereignislisten und die unteren Adapterkarten erreichbar.
8
- - **Saubere Anmeldung:** Loginname und Passwort verwenden feste Platzhalter statt kollidierender Floating Labels. Die Karte ist moderat größer, wächst bei Fehlermeldungen automatisch und besitzt keine innere horizontale oder vertikale Scrollleiste.
9
- - **Reales Kontopasswort beim Reset:** Ein zulässiger Reset schreibt das Startpasswort `nexowatt` mit der ioBroker-Passwortschnittstelle in das tatsächliche Benutzerkonto. Die EOS-Erstanmeldungsmerkmale werden getrennt davon aktualisiert, damit der neue Passwort-Hash nicht wieder überschrieben wird.
10
- - **Persönliches Passwort nach der ersten Anmeldung:** Das neue Kennwort wird serverseitig validiert, in das reale Benutzerkonto geschrieben, anschließend geprüft und erst danach wird der Erstanmeldungsstatus beendet.
11
- - **Saubere Rollenbegrenzung:** Admin/Service darf verwaltete Installateur- und Endkundenkonten zurücksetzen. Installateure dürfen ausschließlich ausdrücklich zugeordnete Endkundenkonten zurücksetzen. Admin-, Eigen-, deaktivierte und nicht verwaltete Konten bleiben geschützt.
12
-
13
- ## Unveränderte Produktregeln
14
-
15
- - Die EMS-Live-Kachel ist ausschließlich lesend und verändert keine Regelung, Geräte- oder Sollwerte.
16
- - Der NexoWatt UI Adapter stellt die Diagnosewerte weiterhin unter `nexowatt-ui.*.info.adminOverview.*` bereit.
17
- - EOS Assist bleibt bis zur vollständigen Neuimplementierung deaktiviert.
18
- - Standardport des EOS Admin bleibt `8081`.
19
-
20
- ## Freigabestatus
21
-
22
- Alle paketinternen Prüfungen, die isolierte Browser-Geometrieprüfung, der simulierte Passwortablauf und der npm-Publish-Dry-Run müssen erfolgreich sein. Vor dem Verkauf ist zusätzlich die Checkliste in `RELEASE_ACCEPTANCE_V7.9.98.md` einmal auf einem realen EOS-Testcontroller abzuarbeiten.
@@ -1,48 +0,0 @@
1
- # Release-Abnahme – NexoWatt EOS Admin 7.9.98
2
-
3
- Diese Checkliste ist vor der Verkaufsfreigabe einmal vollständig auf einem realen EOS-Testcontroller abzuarbeiten.
4
-
5
- ## Installation und Versionsstand
6
-
7
- - [ ] `iobroker.eos-admin` zeigt Version `7.9.98`.
8
- - [ ] `eos-admin.0` startet ohne Fehler und ist auf Port `8081` erreichbar.
9
- - [ ] Nach `Strg + F5` werden ausschließlich die v98-Laufzeitdateien geladen.
10
- - [ ] Ein kompletter Neustart des EOS-Controllers führt wieder zu einer erreichbaren Oberfläche.
11
-
12
- ## Anmeldung
13
-
14
- - [ ] Loginname und Passwort überlappen weder Rahmen noch Beschriftungen.
15
- - [ ] Die Anmeldekarte besitzt keine innere horizontale oder vertikale Scrollleiste.
16
- - [ ] Eine absichtlich falsche Anmeldung zeigt die vollständige Fehlermeldung innerhalb der Karte.
17
- - [ ] Die Karte bleibt bei 1920 × 1080 und 1366 × 768 vollständig bedienbar.
18
-
19
- ## Übersicht und EMS
20
-
21
- - [ ] Header und Navigation bleiben stehen.
22
- - [ ] Der Cockpit-Inhalt lässt sich bis zur letzten Karte vertikal scrollen.
23
- - [ ] EMS-Budget, Ladeleistung, Speicher, Regelentscheidungen und Ereignisse werden angezeigt.
24
- - [ ] Die Kachel aktualisiert sich mit realen Werten aus `nexowatt-ui.*.info.adminOverview.*`.
25
- - [ ] Die EMS-Kachel besitzt keine Schreibfunktion und verändert keine Sollwerte.
26
-
27
- ## Rollen und Passwort-Reset
28
-
29
- - [ ] Admin/Service kann `guest`, `user` und `installer` zurücksetzen, sofern diese Konten ausdrücklich einer verwalteten EOS-Rolle zugeordnet sind.
30
- - [ ] Installateur kann ausschließlich ausdrücklich zugeordnete Endkundenkonten zurücksetzen.
31
- - [ ] Admin-Konto, eigenes Konto, deaktivierte und nicht verwaltete Konten werden abgewiesen.
32
- - [ ] Nach dem Reset funktioniert die Anmeldung mit dem Startpasswort `nexowatt`.
33
- - [ ] Das bisherige persönliche Kennwort ist nach dem Reset nicht mehr gültig.
34
-
35
- ## Persönliches Passwort
36
-
37
- - [ ] Die Anmeldung mit `nexowatt` öffnet unmittelbar die Seite „Persönliches Passwort festlegen“.
38
- - [ ] Zu kurze, nicht übereinstimmende oder zu einfache Kennwörter werden verständlich abgewiesen.
39
- - [ ] Ein gültiges neues Kennwort wird gespeichert.
40
- - [ ] Nach erfolgreichem Speichern wird die alte Sitzung beendet.
41
- - [ ] Die erneute Anmeldung funktioniert ausschließlich mit dem neu vergebenen Kennwort.
42
- - [ ] Im nativen Benutzereditor ist weiterhin ein Passwort-Hash für das richtige Benutzerkonto vorhanden.
43
-
44
- ## Abschluss
45
-
46
- - [ ] EOS Assist bleibt ausgeblendet.
47
- - [ ] Sicherung, Dienste, Module, Datenpunkte und Systemlogs bleiben erreichbar.
48
- - [ ] Es treten während der Abnahme keine neuen Fehler im EOS-Admin-Log auf.
@@ -1,32 +0,0 @@
1
- # Release Notes – NexoWatt EOS Admin 7.9.98
2
-
3
- ## Übersicht und Bedienung
4
-
5
- - Der Cockpit-Inhalt kann jetzt bis zum letzten Element vertikal gescrollt werden.
6
- - Header und Hauptnavigation bleiben währenddessen stehen.
7
- - Die EMS-Live-Diagnose, aktuelle Regelentscheidungen, Ereignisse und nachfolgende Adapterkarten werden nicht mehr am unteren Fensterrand abgeschnitten.
8
-
9
- ## Anmeldung
10
-
11
- - Überlappende MUI-Feldbeschriftungen wurden entfernt.
12
- - Loginname und Passwort verwenden klar erkennbare Platzhalter.
13
- - Die Anmeldekarte wurde nur moderat vergrößert und wächst bei einer Fehlermeldung automatisch.
14
- - Innere horizontale und vertikale Scrollleisten bleiben ausgeschlossen.
15
-
16
- ## Konten und Kennwörter
17
-
18
- - Ein Kontoreset schreibt das reale ioBroker-Kontopasswort auf `nexowatt`.
19
- - Der Passwortschreibvorgang wird mit der Controller-Passwortprüfung verifiziert, bevor Erfolg gemeldet wird.
20
- - Die EOS-Erstanmeldungsmerkmale werden ausschließlich als Metadaten erweitert; der zuvor geschriebene Passwort-Hash wird nicht durch ein altes Benutzerobjekt überschrieben.
21
- - Admin/Service darf verwaltete Installateur- und Endkundenkonten zurücksetzen.
22
- - Installateure dürfen ausschließlich ausdrücklich zugeordnete Endkundenkonten zurücksetzen.
23
- - Admin-, Eigen-, deaktivierte und nicht verwaltete Konten werden weiterhin abgewiesen.
24
- - Die persönliche Passwortvergabe nach der Anmeldung mit `nexowatt` schreibt und prüft ebenfalls das reale Benutzerkennwort.
25
- - Nach erfolgreicher Passwortvergabe werden vorhandene Anmeldesitzungen beendet und der Erstanmeldungsstatus entfernt.
26
-
27
- ## Stabilität und Aktualisierung
28
-
29
- - Paket-, Lockfile-, io-package-, Frontend- und Repository-Versionen werden vor der Veröffentlichung auf `7.9.98` synchronisiert.
30
- - Alte Stable-Laufzeitdateien wie v97 werden beim Merge-Update automatisch entfernt.
31
- - Die EMS-Live-Diagnose bleibt read-only.
32
- - EOS Assist bleibt deaktiviert.