Revised checkbox-tree functions and related
This commit is contained in:
@@ -0,0 +1,30 @@
|
||||
[
|
||||
{
|
||||
"id": "PAN-242777",
|
||||
"summary": "Fixed an issue where users previously reported limitations due to session count caps when utilizing **Web Proxy** features on PA-5400 Series Firewalls. To address these performance complaints and support higher traffic volumes, we have increased the maximum session capacity on specific **PA-5400F** series platforms, leveraging available system memory. This update ensures greater capacity and stability for high-volume environments.The supported session limits are:| Platform | Max Sessions |\n| -------- | ------------ |\n| PA-5410 | 95K |\n| PA-5420 | 95K |\n| PA-5430 | 95K |\n| PA-5440 | 225K |\n| PA-5445 | 250K |\n| PA-5450 | 1.28M |",
|
||||
"resolved": "",
|
||||
"caveat": "",
|
||||
"renderedHtml": "<p>Fixed an issue where users previously reported limitations due to session count caps when utilizing <strong>Web Proxy</strong> features on PA-5400 Series Firewalls. To address these performance complaints and support higher traffic volumes, we have increased the maximum session capacity on specific <strong>PA-5400F</strong> series platforms, leveraging available system memory. This update ensures greater capacity and stability for high-volume environments.The supported session limits are:| Platform | Max Sessions |\n| -------- | ------------ |\n| PA-5410 | 95K |\n| PA-5420 | 95K |\n| PA-5430 | 95K |\n| PA-5440 | 225K |\n| PA-5445 | 250K |\n| PA-5450 | 1.28M |</p>\n"
|
||||
},
|
||||
{
|
||||
"id": "PAN-291499",
|
||||
"summary": "Fixed an issue where newly deployed firewalls were unable to connect to the Strata Logging Service (SLS) until after a reboot, license fetch, or management server restart.",
|
||||
"resolved": "",
|
||||
"caveat": "VM-Series firewalls on Amazon Web Services (AWS) environments only",
|
||||
"renderedHtml": "<div><em>Caveat: VM-Series firewalls on Amazon Web Services (AWS) environments only</em></div><p>Fixed an issue where newly deployed firewalls were unable to connect to the Strata Logging Service (SLS) until after a reboot, license fetch, or management server restart.</p>\n"
|
||||
},
|
||||
{
|
||||
"id": "PAN-288726",
|
||||
"summary": "Fixed an issue where the useridd process stopped responding due to a Security policy rule ID being set to 0, which caused the last configuration retrieval to fail.",
|
||||
"resolved": "",
|
||||
"caveat": "",
|
||||
"renderedHtml": "<p>Fixed an issue where the useridd process stopped responding due to a Security policy rule ID being set to 0, which caused the last configuration retrieval to fail.</p>\n"
|
||||
},
|
||||
{
|
||||
"id": "PAN-287133",
|
||||
"summary": "Fixed an issue on the Panorama web interface where assigning a policy rule to a group at the top or bottom of the list changed the order of other policy rules.",
|
||||
"resolved": "",
|
||||
"caveat": "",
|
||||
"renderedHtml": "<p>Fixed an issue on the Panorama web interface where assigning a policy rule to a group at the top or bottom of the list changed the order of other policy rules.</p>\n"
|
||||
}
|
||||
]
|
||||
@@ -0,0 +1,70 @@
|
||||
import assert from 'node:assert/strict';
|
||||
import { mkdtemp, mkdir, readFile, rm, writeFile } from 'node:fs/promises';
|
||||
import { join } from 'node:path';
|
||||
import { tmpdir } from 'node:os';
|
||||
import test from 'node:test';
|
||||
import { buildProductTree, enumerateTreePaths } from '../web/js/product-tree-model.js';
|
||||
import { updateProductsFromIssues } from '../scripts/update-products-from-issues.mjs';
|
||||
|
||||
test('product updater rebuilds products and append-only manifest idempotently', async t => {
|
||||
const root = await mkdtemp(join(tmpdir(), 'firewallissues-update-'));
|
||||
t.after(() => rm(root, { recursive: true, force: true }));
|
||||
const issuesDir = join(root, 'issues');
|
||||
const productsPath = join(root, 'products.json');
|
||||
const manifestPath = join(root, 'manifest.json');
|
||||
await mkdir(join(issuesDir, 'Product', 'addressed'), { recursive: true });
|
||||
await mkdir(join(issuesDir, 'Product', 'known'), { recursive: true });
|
||||
await writeFile(join(issuesDir, 'Product', 'addressed', '1.2.3-h2.md'), 'addressed');
|
||||
await writeFile(join(issuesDir, 'Product', 'addressed', '1.2.3.md'), 'addressed');
|
||||
await writeFile(join(issuesDir, 'Product', 'known', '1.2.4.md'), 'known');
|
||||
|
||||
const initialProducts = {
|
||||
Product: {
|
||||
1: {
|
||||
'1.2': {
|
||||
addressed: ['obsolete.md'],
|
||||
known: []
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
const rootPath = JSON.stringify(['Product']);
|
||||
await writeFile(productsPath, `${JSON.stringify(initialProducts, null, 2)}\n`);
|
||||
await writeFile(manifestPath, `${JSON.stringify({ schema: 1, nodes: [rootPath, 'legacy-path', null] }, null, 2)}\n`);
|
||||
|
||||
const first = await updateProductsFromIssues({ issuesDir, productsPath, manifestPath });
|
||||
assert.equal(first.records, 3);
|
||||
assert.equal(first.unmatched.length, 0);
|
||||
assert.ok(first.appended.length > 0);
|
||||
assert.deepEqual(first.missing, ['legacy-path']);
|
||||
|
||||
const products = JSON.parse(await readFile(productsPath, 'utf8'));
|
||||
assert.deepEqual(products.Product[1]['1.2'].addressed, ['1.2.3.md', '1.2.3-h2.md']);
|
||||
assert.deepEqual(products.Product[1]['1.2'].known, ['1.2.4.md']);
|
||||
|
||||
const manifest = JSON.parse(await readFile(manifestPath, 'utf8'));
|
||||
assert.deepEqual(manifest.nodes.slice(0, 3), [rootPath, 'legacy-path', null]);
|
||||
const renderedPaths = enumerateTreePaths(buildProductTree(products));
|
||||
assert.ok(renderedPaths.every(path => manifest.nodes.includes(path)));
|
||||
|
||||
const second = await updateProductsFromIssues({ issuesDir, productsPath, manifestPath });
|
||||
assert.deepEqual(second.appended, []);
|
||||
assert.deepEqual(JSON.parse(await readFile(manifestPath, 'utf8')), manifest);
|
||||
});
|
||||
|
||||
test('product updater refuses to rewrite when no issue files are found', async t => {
|
||||
const root = await mkdtemp(join(tmpdir(), 'firewallissues-empty-update-'));
|
||||
t.after(() => rm(root, { recursive: true, force: true }));
|
||||
const issuesDir = join(root, 'issues');
|
||||
const productsPath = join(root, 'products.json');
|
||||
const manifestPath = join(root, 'manifest.json');
|
||||
await mkdir(issuesDir);
|
||||
await writeFile(productsPath, '{}\n');
|
||||
await writeFile(manifestPath, '{"schema":1,"nodes":[]}\n');
|
||||
|
||||
await assert.rejects(
|
||||
updateProductsFromIssues({ issuesDir, productsPath, manifestPath }),
|
||||
/No '<version>\.md' issue files found/
|
||||
);
|
||||
assert.equal(await readFile(productsPath, 'utf8'), '{}\n');
|
||||
});
|
||||
Reference in New Issue
Block a user