@robinmordasiewicz/f5xc-xcsh 2.0.41-2601192346 → 2.0.43-2601200312

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/dist/index.js +325 -67
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -41229,8 +41229,8 @@ var init_logo_renderer = __esm({
41229
41229
 
41230
41230
  // src/branding/index.ts
41231
41231
  function getVersion() {
41232
- if ("v2.0.41-2601192346") {
41233
- return "v2.0.41-2601192346";
41232
+ if ("v2.0.43-2601200312") {
41233
+ return "v2.0.43-2601200312";
41234
41234
  }
41235
41235
  if (process.env.XCSH_VERSION) {
41236
41236
  return process.env.XCSH_VERSION;
@@ -162672,7 +162672,7 @@ function getConflictsForFlag2(flagName, resourceType) {
162672
162672
  }
162673
162673
  return Array.from(conflicts);
162674
162674
  }
162675
- var HEALTHCHECK_CREATION_FLAGS, ORIGIN_POOL_CREATION_FLAGS, CREATION_FLAGS_REGISTRY;
162675
+ var HEALTHCHECK_CREATION_FLAGS, ORIGIN_POOL_CREATION_FLAGS, HTTP_LOADBALANCER_CREATION_FLAGS, APP_FIREWALL_CREATION_FLAGS, CREATION_FLAGS_REGISTRY;
162676
162676
  var init_creation_flags = __esm({
162677
162677
  "src/repl/completion/creation-flags.ts"() {
162678
162678
  "use strict";
@@ -162863,27 +162863,7 @@ var init_creation_flags = __esm({
162863
162863
  priority: 1
162864
162864
  // Highest priority - always first
162865
162865
  },
162866
- // Port configuration (mutually exclusive group)
162867
- {
162868
- name: "--port",
162869
- description: "Backend port (1-65535)",
162870
- required: false,
162871
- hasValue: true,
162872
- valueType: "integer"
162873
- },
162874
- {
162875
- name: "--automatic-port",
162876
- description: "Use automatic port selection",
162877
- required: false,
162878
- hasValue: false
162879
- },
162880
- {
162881
- name: "--lb-port",
162882
- description: "Use load balancer port",
162883
- required: false,
162884
- hasValue: false
162885
- },
162886
- // Origin Server Types (ALL 10 - REPEATABLE)
162866
+ // Origin Server Types (ALL 10 - REPEATABLE) - Priority 15-20
162887
162867
  {
162888
162868
  name: "--public-ip",
162889
162869
  description: "Public IP origin server",
@@ -162891,7 +162871,8 @@ var init_creation_flags = __esm({
162891
162871
  hasValue: true,
162892
162872
  valueType: "string",
162893
162873
  isRepeatable: true,
162894
- maxOccurrences: 32
162874
+ maxOccurrences: 32,
162875
+ priority: 15
162895
162876
  },
162896
162877
  {
162897
162878
  name: "--public-name",
@@ -162900,7 +162881,8 @@ var init_creation_flags = __esm({
162900
162881
  hasValue: true,
162901
162882
  valueType: "string",
162902
162883
  isRepeatable: true,
162903
- maxOccurrences: 32
162884
+ maxOccurrences: 32,
162885
+ priority: 15
162904
162886
  },
162905
162887
  {
162906
162888
  name: "--private-ip",
@@ -162909,7 +162891,8 @@ var init_creation_flags = __esm({
162909
162891
  hasValue: true,
162910
162892
  valueType: "string",
162911
162893
  isRepeatable: true,
162912
- maxOccurrences: 32
162894
+ maxOccurrences: 32,
162895
+ priority: 16
162913
162896
  },
162914
162897
  {
162915
162898
  name: "--private-name",
@@ -162918,7 +162901,8 @@ var init_creation_flags = __esm({
162918
162901
  hasValue: true,
162919
162902
  valueType: "string",
162920
162903
  isRepeatable: true,
162921
- maxOccurrences: 32
162904
+ maxOccurrences: 32,
162905
+ priority: 16
162922
162906
  },
162923
162907
  {
162924
162908
  name: "--k8s-service",
@@ -162927,7 +162911,8 @@ var init_creation_flags = __esm({
162927
162911
  hasValue: true,
162928
162912
  valueType: "string",
162929
162913
  isRepeatable: true,
162930
- maxOccurrences: 32
162914
+ maxOccurrences: 32,
162915
+ priority: 17
162931
162916
  },
162932
162917
  {
162933
162918
  name: "--consul-service",
@@ -162936,7 +162921,18 @@ var init_creation_flags = __esm({
162936
162921
  hasValue: true,
162937
162922
  valueType: "string",
162938
162923
  isRepeatable: true,
162939
- maxOccurrences: 32
162924
+ maxOccurrences: 32,
162925
+ priority: 17
162926
+ },
162927
+ {
162928
+ name: "--cbip-service",
162929
+ description: "Cloud-based IP service",
162930
+ required: false,
162931
+ hasValue: true,
162932
+ valueType: "string",
162933
+ isRepeatable: true,
162934
+ maxOccurrences: 32,
162935
+ priority: 17
162940
162936
  },
162941
162937
  {
162942
162938
  name: "--custom-endpoint",
@@ -162945,7 +162941,8 @@ var init_creation_flags = __esm({
162945
162941
  hasValue: true,
162946
162942
  valueType: "string",
162947
162943
  isRepeatable: true,
162948
- maxOccurrences: 32
162944
+ maxOccurrences: 32,
162945
+ priority: 18
162949
162946
  },
162950
162947
  {
162951
162948
  name: "--vn-private-ip",
@@ -162954,7 +162951,8 @@ var init_creation_flags = __esm({
162954
162951
  hasValue: true,
162955
162952
  valueType: "string",
162956
162953
  isRepeatable: true,
162957
- maxOccurrences: 32
162954
+ maxOccurrences: 32,
162955
+ priority: 19
162958
162956
  },
162959
162957
  {
162960
162958
  name: "--vn-private-name",
@@ -162963,63 +162961,88 @@ var init_creation_flags = __esm({
162963
162961
  hasValue: true,
162964
162962
  valueType: "string",
162965
162963
  isRepeatable: true,
162966
- maxOccurrences: 32
162964
+ maxOccurrences: 32,
162965
+ priority: 19
162967
162966
  },
162967
+ // Site reference (for private origins) - Priority 20
162968
162968
  {
162969
- name: "--cbip-service",
162970
- description: "Cloud-based IP service",
162969
+ name: "--site",
162970
+ description: "Site reference for private origins",
162971
162971
  required: false,
162972
162972
  hasValue: true,
162973
162973
  valueType: "string",
162974
- isRepeatable: true,
162975
- maxOccurrences: 32
162974
+ priority: 20
162976
162975
  },
162977
- // Load Balancing Algorithm
162976
+ // Port configuration (mutually exclusive group) - Priority 25-26
162978
162977
  {
162979
- name: "--algorithm",
162980
- description: "Load balancing algorithm",
162978
+ name: "--port",
162979
+ description: "Backend port (1-65535)",
162981
162980
  required: false,
162982
162981
  hasValue: true,
162983
- valueType: "enum",
162984
- enumValues: [
162985
- "ROUND_ROBIN",
162986
- "LEAST_ACTIVE",
162987
- "RANDOM",
162988
- "SOURCE_IP_STICKINESS",
162989
- "COOKIE_STICKINESS",
162990
- "RING_HASH"
162991
- ]
162982
+ valueType: "integer",
162983
+ recommendedValue: 443,
162984
+ priority: 25
162992
162985
  },
162993
- // Health Checks (repeatable, max 4)
162994
162986
  {
162995
- name: "--health-check",
162996
- description: "Health check reference",
162987
+ name: "--automatic-port",
162988
+ description: "Use automatic port selection",
162997
162989
  required: false,
162998
- hasValue: true,
162999
- valueType: "string",
163000
- isRepeatable: true,
163001
- maxOccurrences: 4
162990
+ hasValue: false,
162991
+ priority: 26
162992
+ },
162993
+ {
162994
+ name: "--lb-port",
162995
+ description: "Use load balancer port",
162996
+ required: false,
162997
+ hasValue: false,
162998
+ priority: 26
163002
162999
  },
163003
- // TLS Configuration
163000
+ // TLS Configuration - Priority 32
163004
163001
  {
163005
163002
  name: "--no-tls",
163006
163003
  description: "Disable TLS for origin connections",
163007
163004
  required: false,
163008
- hasValue: false
163005
+ hasValue: false,
163006
+ priority: 32
163009
163007
  },
163010
163008
  {
163011
163009
  name: "--use-tls",
163012
163010
  description: "Enable TLS for origin connections",
163013
163011
  required: false,
163014
- hasValue: false
163012
+ hasValue: false,
163013
+ priority: 32
163015
163014
  },
163016
- // Site reference (for private origins)
163015
+ // Load Balancing Algorithm - Priority 35
163017
163016
  {
163018
- name: "--site",
163019
- description: "Site reference for private origins",
163017
+ name: "--algorithm",
163018
+ description: "Load balancing algorithm",
163019
+ required: false,
163020
+ hasValue: true,
163021
+ valueType: "enum",
163022
+ enumValues: [
163023
+ "ROUND_ROBIN",
163024
+ "LEAST_REQUEST",
163025
+ "RANDOM",
163026
+ "SOURCE_IP_STICKINESS",
163027
+ "COOKIE_STICKINESS",
163028
+ "RING_HASH",
163029
+ "LB_OVERRIDE"
163030
+ ],
163031
+ defaultValue: "ROUND_ROBIN",
163032
+ hasServerDefault: true,
163033
+ recommendedValue: "LB_OVERRIDE",
163034
+ priority: 35
163035
+ },
163036
+ // Health Checks (repeatable, max 4) - Priority 38
163037
+ {
163038
+ name: "--health-check",
163039
+ description: "Health check reference",
163020
163040
  required: false,
163021
163041
  hasValue: true,
163022
- valueType: "string"
163042
+ valueType: "string",
163043
+ isRepeatable: true,
163044
+ maxOccurrences: 4,
163045
+ priority: 38
163023
163046
  },
163024
163047
  // Connection Pool - Parent Flag (Priority 30)
163025
163048
  {
@@ -163029,6 +163052,7 @@ var init_creation_flags = __esm({
163029
163052
  hasValue: true,
163030
163053
  valueType: "enum",
163031
163054
  enumValues: ["default", "enable-reuse", "disable-reuse"],
163055
+ recommendedValue: "enable-reuse",
163032
163056
  priority: 30
163033
163057
  },
163034
163058
  // Health Check Port - Parent Flag (Priority 35)
@@ -163064,6 +163088,7 @@ var init_creation_flags = __esm({
163064
163088
  enumValues: ["DISTRIBUTED", "LOCAL_ONLY", "LOCAL_PREFERRED"],
163065
163089
  defaultValue: "DISTRIBUTED",
163066
163090
  hasServerDefault: true,
163091
+ recommendedValue: "LOCAL_PREFERRED",
163067
163092
  priority: 40
163068
163093
  },
163069
163094
  // Advanced Timeouts (Priority 45)
@@ -163292,9 +163317,230 @@ var init_creation_flags = __esm({
163292
163317
  priority: 80
163293
163318
  }
163294
163319
  ];
163320
+ HTTP_LOADBALANCER_CREATION_FLAGS = [
163321
+ // Required - Name
163322
+ {
163323
+ name: "--name",
163324
+ description: "HTTP load balancer name",
163325
+ required: true,
163326
+ hasValue: true,
163327
+ valueType: "string",
163328
+ priority: 1
163329
+ },
163330
+ // Domains (virtual hosts) - Priority 10
163331
+ {
163332
+ name: "--domain",
163333
+ description: "Domain name for virtual host (e.g., example.com)",
163334
+ required: false,
163335
+ hasValue: true,
163336
+ valueType: "string",
163337
+ isRepeatable: true,
163338
+ maxOccurrences: 64,
163339
+ priority: 10
163340
+ },
163341
+ // Port Configuration - Priority 15
163342
+ {
163343
+ name: "--http-port",
163344
+ description: "HTTP listening port (default: 80)",
163345
+ required: false,
163346
+ hasValue: true,
163347
+ valueType: "integer",
163348
+ defaultValue: 80,
163349
+ hasServerDefault: true,
163350
+ priority: 15
163351
+ },
163352
+ {
163353
+ name: "--https-port",
163354
+ description: "HTTPS listening port (default: 443)",
163355
+ required: false,
163356
+ hasValue: true,
163357
+ valueType: "integer",
163358
+ defaultValue: 443,
163359
+ hasServerDefault: true,
163360
+ recommendedValue: 443,
163361
+ priority: 15
163362
+ },
163363
+ // TLS Configuration - Priority 20
163364
+ {
163365
+ name: "--tls-certificate",
163366
+ description: "TLS certificate reference for HTTPS",
163367
+ required: false,
163368
+ hasValue: true,
163369
+ valueType: "string",
163370
+ priority: 20
163371
+ },
163372
+ {
163373
+ name: "--http-redirect",
163374
+ description: "Redirect HTTP to HTTPS automatically",
163375
+ required: false,
163376
+ hasValue: false,
163377
+ priority: 21
163378
+ },
163379
+ // Origin Pool - Priority 25
163380
+ {
163381
+ name: "--origin-pool",
163382
+ description: "Default origin pool for backend traffic",
163383
+ required: false,
163384
+ hasValue: true,
163385
+ valueType: "string",
163386
+ priority: 25
163387
+ },
163388
+ // Advertise Policy - Priority 30
163389
+ {
163390
+ name: "--advertise-policy",
163391
+ description: "Where to advertise this load balancer",
163392
+ required: false,
163393
+ hasValue: true,
163394
+ valueType: "enum",
163395
+ enumValues: ["INTERNET", "VIRTUAL_SITE", "CUSTOM"],
163396
+ recommendedValue: "INTERNET",
163397
+ priority: 30
163398
+ },
163399
+ // WAF/Security - Priority 40
163400
+ {
163401
+ name: "--app-firewall",
163402
+ description: "Application firewall (WAF) policy reference",
163403
+ required: false,
163404
+ hasValue: true,
163405
+ valueType: "string",
163406
+ priority: 40
163407
+ },
163408
+ {
163409
+ name: "--service-policy",
163410
+ description: "Service policy reference for rate limiting",
163411
+ required: false,
163412
+ hasValue: true,
163413
+ valueType: "string",
163414
+ priority: 41
163415
+ },
163416
+ // Advanced Features - Priority 50+
163417
+ {
163418
+ name: "--enable-api-discovery",
163419
+ description: "Enable automatic API endpoint discovery",
163420
+ required: false,
163421
+ hasValue: false,
163422
+ priority: 50
163423
+ },
163424
+ {
163425
+ name: "--bot-defense",
163426
+ description: "Bot defense policy reference",
163427
+ required: false,
163428
+ hasValue: true,
163429
+ valueType: "string",
163430
+ priority: 51
163431
+ },
163432
+ {
163433
+ name: "--enable-ddos",
163434
+ description: "Enable DDoS protection",
163435
+ required: false,
163436
+ hasValue: false,
163437
+ priority: 52
163438
+ }
163439
+ ];
163440
+ APP_FIREWALL_CREATION_FLAGS = [
163441
+ // Required - Name
163442
+ {
163443
+ name: "--name",
163444
+ description: "Application firewall name",
163445
+ required: true,
163446
+ hasValue: true,
163447
+ valueType: "string",
163448
+ priority: 1
163449
+ },
163450
+ // Blocking Mode - Priority 10
163451
+ {
163452
+ name: "--blocking-mode",
163453
+ description: "WAF enforcement mode",
163454
+ required: false,
163455
+ hasValue: true,
163456
+ valueType: "enum",
163457
+ enumValues: ["MONITORING", "BLOCKING"],
163458
+ defaultValue: "MONITORING",
163459
+ hasServerDefault: true,
163460
+ recommendedValue: "BLOCKING",
163461
+ priority: 10
163462
+ },
163463
+ // Detection Settings - Priority 15
163464
+ {
163465
+ name: "--detection-mode",
163466
+ description: "Attack detection sensitivity",
163467
+ required: false,
163468
+ hasValue: true,
163469
+ valueType: "enum",
163470
+ enumValues: ["LOW", "MEDIUM", "HIGH", "CUSTOM"],
163471
+ defaultValue: "MEDIUM",
163472
+ hasServerDefault: true,
163473
+ recommendedValue: "HIGH",
163474
+ priority: 15
163475
+ },
163476
+ // Attack Types - Priority 20
163477
+ {
163478
+ name: "--enable-sql-injection",
163479
+ description: "Enable SQL injection detection",
163480
+ required: false,
163481
+ hasValue: false,
163482
+ priority: 20
163483
+ },
163484
+ {
163485
+ name: "--enable-xss",
163486
+ description: "Enable cross-site scripting (XSS) detection",
163487
+ required: false,
163488
+ hasValue: false,
163489
+ priority: 20
163490
+ },
163491
+ {
163492
+ name: "--enable-command-injection",
163493
+ description: "Enable command injection detection",
163494
+ required: false,
163495
+ hasValue: false,
163496
+ priority: 20
163497
+ },
163498
+ // Violation Settings - Priority 30
163499
+ {
163500
+ name: "--allowed-response-codes",
163501
+ description: "Allowed HTTP response codes (comma-separated)",
163502
+ required: false,
163503
+ hasValue: true,
163504
+ valueType: "string",
163505
+ priority: 30
163506
+ },
163507
+ {
163508
+ name: "--max-request-size",
163509
+ description: "Maximum request size in bytes",
163510
+ required: false,
163511
+ hasValue: true,
163512
+ valueType: "integer",
163513
+ defaultValue: 10485760,
163514
+ priority: 31
163515
+ },
163516
+ // Advanced Features - Priority 40+
163517
+ {
163518
+ name: "--enable-api-protection",
163519
+ description: "Enable API-specific protection",
163520
+ required: false,
163521
+ hasValue: false,
163522
+ priority: 40
163523
+ },
163524
+ {
163525
+ name: "--enable-bot-protection",
163526
+ description: "Enable bot detection integration",
163527
+ required: false,
163528
+ hasValue: false,
163529
+ priority: 41
163530
+ },
163531
+ {
163532
+ name: "--enable-threat-campaigns",
163533
+ description: "Enable threat campaign protection",
163534
+ required: false,
163535
+ hasValue: false,
163536
+ priority: 42
163537
+ }
163538
+ ];
163295
163539
  CREATION_FLAGS_REGISTRY = /* @__PURE__ */ new Map([
163296
163540
  ["healthcheck", HEALTHCHECK_CREATION_FLAGS],
163297
- ["origin_pool", ORIGIN_POOL_CREATION_FLAGS]
163541
+ ["origin_pool", ORIGIN_POOL_CREATION_FLAGS],
163542
+ ["http_loadbalancer", HTTP_LOADBALANCER_CREATION_FLAGS],
163543
+ ["app_firewall", APP_FIREWALL_CREATION_FLAGS]
163298
163544
  ]);
163299
163545
  }
163300
163546
  });
@@ -163546,7 +163792,19 @@ async function getQuotaForResourceType(apiClient, namespace, resourceType) {
163546
163792
  namespace,
163547
163793
  mapping.quotaName
163548
163794
  );
163549
- if (!usage || usage.limit <= 0) {
163795
+ if (!usage) {
163796
+ return null;
163797
+ }
163798
+ if (usage.limit < 0) {
163799
+ return {
163800
+ current: usage.current,
163801
+ limit: usage.limit,
163802
+ percentage: 0,
163803
+ level: "none",
163804
+ display: `${usage.current} (unlimited)`
163805
+ };
163806
+ }
163807
+ if (usage.limit === 0) {
163550
163808
  return null;
163551
163809
  }
163552
163810
  const percentage = Math.round(usage.current / usage.limit * 100);
@@ -164880,8 +165138,8 @@ var init_completer = __esm({
164880
165138
  category: "value"
164881
165139
  },
164882
165140
  {
164883
- text: "LEAST_ACTIVE",
164884
- description: "Least active connections",
165141
+ text: "LEAST_REQUEST",
165142
+ description: "Least request algorithm",
164885
165143
  category: "value"
164886
165144
  },
164887
165145
  {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@robinmordasiewicz/f5xc-xcsh",
3
- "version": "2.0.41-2601192346",
3
+ "version": "2.0.43-2601200312",
4
4
  "description": "F5 Distributed Cloud Shell - Interactive CLI for F5 XC",
5
5
  "type": "module",
6
6
  "bin": {