mybase 1.0.49 → 1.0.50

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 (2) hide show
  1. package/mybase.js +10 -1
  2. package/package.json +1 -1
package/mybase.js CHANGED
@@ -676,6 +676,14 @@ function decryptAES_CBC_NOIV(encryptedHex, encryptionKey) {
676
676
  }
677
677
  }
678
678
 
679
+ function MaxRuntimeHours(hours=24) {
680
+ setTimeout(() => {
681
+ console.log(`Max runtime of ${hours} hours reached, exiting`)
682
+ process.exit(0)
683
+ }, hours * 60 * 60 * 1000)
684
+ }
685
+
686
+
679
687
  function isReservedLANIP(address) {
680
688
  // Define the reserved LAN IP ranges for IPv4 and IPv6.
681
689
  const reservedLANIPRanges = [
@@ -740,5 +748,6 @@ module.exports = {
740
748
  hash_sha512,
741
749
  isReservedLANIP,
742
750
  isLANIp,
743
- isLoopbackIP
751
+ isLoopbackIP,
752
+ MaxRuntimeHours
744
753
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "mybase",
3
- "version": "1.0.49",
3
+ "version": "1.0.50",
4
4
  "description": "",
5
5
  "main": "mybase.js",
6
6
  "scripts": {