pmcf 2.18.0 → 2.18.2
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.
- package/package.json +1 -1
- package/src/ip.mjs +2 -11
- package/src/services/dns.mjs +2 -2
- package/src/subnet.mjs +1 -1
package/package.json
CHANGED
package/src/ip.mjs
CHANGED
|
@@ -230,18 +230,9 @@ export function rangeIP(address, prefix, lowerAdd = 0, upperReduce = 0) {
|
|
|
230
230
|
const definition = isIPv4(address) ? ipv4 : ipv6;
|
|
231
231
|
|
|
232
232
|
const from = _prefix(definition, address, prefix);
|
|
233
|
-
const to =
|
|
234
|
-
|
|
235
|
-
for (
|
|
236
|
-
let i = prefix / definition.segmentLength;
|
|
237
|
-
i < definition.segments;
|
|
238
|
-
i++
|
|
239
|
-
) {
|
|
240
|
-
to[i] = 0xffff;
|
|
241
|
-
}
|
|
233
|
+
const to = from | ((1n << BigInt(definition.bitLength - prefix)) - 1n);
|
|
242
234
|
|
|
243
|
-
|
|
244
|
-
return [_encode(definition, from + BigInt(lowerAdd)), to];
|
|
235
|
+
return [_encode(definition, from + BigInt(lowerAdd)), _encode(definition, to - BigInt(upperReduce))];
|
|
245
236
|
}
|
|
246
237
|
|
|
247
238
|
export function normalizeCIDR(address) {
|
package/src/services/dns.mjs
CHANGED
|
@@ -296,8 +296,8 @@ async function generateZoneDefs(dns, location, packageData) {
|
|
|
296
296
|
addHook(
|
|
297
297
|
packageData.properties.hooks,
|
|
298
298
|
"post_upgrade",
|
|
299
|
-
|
|
300
|
-
|
|
299
|
+
// `rm -f ${foreignZones.map(zone => `/var/lib/named/${zone.file}.jnl`)}\n` +
|
|
300
|
+
// "systemctl try-reload-or-restart named\n" +
|
|
301
301
|
`/usr/bin/named-hostname-info ${foreignZones
|
|
302
302
|
.map(zone => zone.id)
|
|
303
303
|
.join(" ")}|/usr/bin/named-hostname-update`
|
package/src/subnet.mjs
CHANGED