alamin655 commited on
Commit
9bb1544
·
unverified ·
2 Parent(s): 07bbea8 abc59b2

Merge pull request #386 from SaranaDheeraj/rolling

Browse files

🔒️ More secure hashing algorithm like `BLAKE3` instead of `md5` hashing algorithm

Files changed (3) hide show
  1. Cargo.lock +197 -139
  2. Cargo.toml +2 -2
  3. src/cache/redis_cacher.rs +2 -2
Cargo.lock CHANGED
@@ -14,7 +14,7 @@ dependencies = [
14
  "futures-sink",
15
  "memchr",
16
  "pin-project-lite",
17
- "tokio 1.34.0",
18
  "tokio-util",
19
  "tracing",
20
  ]
@@ -31,7 +31,7 @@ dependencies = [
31
  "futures-util",
32
  "log",
33
  "once_cell",
34
- "smallvec 1.11.2",
35
  ]
36
 
37
  [[package]]
@@ -87,7 +87,7 @@ dependencies = [
87
  "derive_more",
88
  "encoding_rs",
89
  "futures-core",
90
- "http 0.2.11",
91
  "httparse",
92
  "httpdate",
93
  "itoa 1.0.9",
@@ -98,8 +98,8 @@ dependencies = [
98
  "pin-project-lite",
99
  "rand 0.8.5",
100
  "sha1",
101
- "smallvec 1.11.2",
102
- "tokio 1.34.0",
103
  "tokio-util",
104
  "tracing",
105
  ]
@@ -121,7 +121,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
121
  checksum = "d66ff4d247d2b160861fa2866457e85706833527840e4133f8f49aa423a38799"
122
  dependencies = [
123
  "bytestring",
124
- "http 0.2.11",
125
  "regex",
126
  "serde",
127
  "tracing",
@@ -134,7 +134,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
134
  checksum = "28f32d40287d3f402ae0028a9d54bef51af15c8769492826a69d28f81893151d"
135
  dependencies = [
136
  "futures-core",
137
- "tokio 1.34.0",
138
  ]
139
 
140
  [[package]]
@@ -150,7 +150,7 @@ dependencies = [
150
  "futures-util",
151
  "mio 0.8.9",
152
  "socket2 0.5.5",
153
- "tokio 1.34.0",
154
  "tracing",
155
  ]
156
 
@@ -209,7 +209,7 @@ dependencies = [
209
  "serde",
210
  "serde_json",
211
  "serde_urlencoded 0.7.1",
212
- "smallvec 1.11.2",
213
  "socket2 0.5.5",
214
  "time 0.3.30",
215
  "url 2.4.1",
@@ -323,6 +323,18 @@ version = "1.6.0"
323
  source = "registry+https://github.com/rust-lang/crates.io-index"
324
  checksum = "bddcadddf5e9015d310179a59bb28c4d4b9920ad0f11e8e14dbadf654890c9a6"
325
 
 
 
 
 
 
 
 
 
 
 
 
 
326
  [[package]]
327
  name = "askama_escape"
328
  version = "0.10.3"
@@ -432,6 +444,19 @@ version = "2.4.1"
432
  source = "registry+https://github.com/rust-lang/crates.io-index"
433
  checksum = "327762f6e5a765692301e5bb513e0d9fef63be86bbc14528052b1cd3e6f03e07"
434
 
 
 
 
 
 
 
 
 
 
 
 
 
 
435
  [[package]]
436
  name = "block-buffer"
437
  version = "0.10.4"
@@ -464,9 +489,9 @@ dependencies = [
464
 
465
  [[package]]
466
  name = "bstr"
467
- version = "1.8.0"
468
  source = "registry+https://github.com/rust-lang/crates.io-index"
469
- checksum = "542f33a8835a0884b006a0c3df3dadd99c0c3f296ed26c2fdc8028e01ad6230c"
470
  dependencies = [
471
  "memchr",
472
  "serde",
@@ -612,18 +637,18 @@ dependencies = [
612
 
613
  [[package]]
614
  name = "clap"
615
- version = "4.4.8"
616
  source = "registry+https://github.com/rust-lang/crates.io-index"
617
- checksum = "2275f18819641850fa26c89acc84d465c1bf91ce57bc2748b28c420473352f64"
618
  dependencies = [
619
  "clap_builder",
620
  ]
621
 
622
  [[package]]
623
  name = "clap_builder"
624
- version = "4.4.8"
625
  source = "registry+https://github.com/rust-lang/crates.io-index"
626
- checksum = "07cdf1b148b25c1e1f7a42225e30a0d99a615cd4637eae7365548dd4529b95bc"
627
  dependencies = [
628
  "anstyle",
629
  "clap_lex",
@@ -654,7 +679,7 @@ dependencies = [
654
  "futures-core",
655
  "memchr",
656
  "pin-project-lite",
657
- "tokio 1.34.0",
658
  "tokio-util",
659
  ]
660
 
@@ -678,6 +703,12 @@ dependencies = [
678
  "syn 1.0.109",
679
  ]
680
 
 
 
 
 
 
 
681
  [[package]]
682
  name = "convert_case"
683
  version = "0.4.0"
@@ -878,7 +909,7 @@ dependencies = [
878
  "dtoa-short",
879
  "itoa 1.0.9",
880
  "phf 0.11.2",
881
- "smallvec 1.11.2",
882
  ]
883
 
884
  [[package]]
@@ -891,7 +922,7 @@ dependencies = [
891
  "dtoa-short",
892
  "itoa 1.0.9",
893
  "phf 0.11.2",
894
- "smallvec 1.11.2",
895
  ]
896
 
897
  [[package]]
@@ -1024,9 +1055,9 @@ dependencies = [
1024
 
1025
  [[package]]
1026
  name = "env_logger"
1027
- version = "0.10.1"
1028
  source = "registry+https://github.com/rust-lang/crates.io-index"
1029
- checksum = "95b3f3e67048839cb0d0781f445682a35113da7121f7c949db0e2be96a4fbece"
1030
  dependencies = [
1031
  "log",
1032
  ]
@@ -1038,20 +1069,14 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
1038
  checksum = "a2d328fc287c61314c4a61af7cfdcbd7e678e39778488c7cb13ec133ce0f4059"
1039
  dependencies = [
1040
  "fsio",
1041
- "indexmap 1.9.3",
1042
  ]
1043
 
1044
- [[package]]
1045
- name = "equivalent"
1046
- version = "1.0.1"
1047
- source = "registry+https://github.com/rust-lang/crates.io-index"
1048
- checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5"
1049
-
1050
  [[package]]
1051
  name = "errno"
1052
- version = "0.3.7"
1053
  source = "registry+https://github.com/rust-lang/crates.io-index"
1054
- checksum = "f258a7194e7f7c2a7837a8913aeab7fd8c383457034fa20ce4dd3dcb813e8eb8"
1055
  dependencies = [
1056
  "libc",
1057
  "windows-sys",
@@ -1370,7 +1395,7 @@ dependencies = [
1370
  "parking_lot 0.12.1",
1371
  "quanta",
1372
  "rand 0.8.5",
1373
- "smallvec 1.11.2",
1374
  ]
1375
 
1376
  [[package]]
@@ -1384,7 +1409,7 @@ dependencies = [
1384
  "fnv",
1385
  "futures 0.1.31",
1386
  "http 0.1.21",
1387
- "indexmap 1.9.3",
1388
  "log",
1389
  "slab",
1390
  "string",
@@ -1393,19 +1418,19 @@ dependencies = [
1393
 
1394
  [[package]]
1395
  name = "h2"
1396
- version = "0.3.22"
1397
  source = "registry+https://github.com/rust-lang/crates.io-index"
1398
- checksum = "4d6250322ef6e60f93f9a2162799302cd6f68f79f6e5d85c8c16f14d1d958178"
1399
  dependencies = [
1400
  "bytes 1.5.0",
1401
  "fnv",
1402
  "futures-core",
1403
  "futures-sink",
1404
  "futures-util",
1405
- "http 0.2.11",
1406
- "indexmap 2.1.0",
1407
  "slab",
1408
- "tokio 1.34.0",
1409
  "tokio-util",
1410
  "tracing",
1411
  ]
@@ -1416,6 +1441,21 @@ version = "1.8.2"
1416
  source = "registry+https://github.com/rust-lang/crates.io-index"
1417
  checksum = "eabb4a44450da02c90444cf74558da904edde8fb4e9035a9a6a4e15445af0bd7"
1418
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1419
  [[package]]
1420
  name = "hashbrown"
1421
  version = "0.12.3"
@@ -1494,9 +1534,9 @@ dependencies = [
1494
 
1495
  [[package]]
1496
  name = "http"
1497
- version = "0.2.11"
1498
  source = "registry+https://github.com/rust-lang/crates.io-index"
1499
- checksum = "8947b1a6fad4393052c7ba1f4cd97bed3e953a95c79c92ad9b051a04611d9fbb"
1500
  dependencies = [
1501
  "bytes 1.5.0",
1502
  "fnv",
@@ -1522,7 +1562,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
1522
  checksum = "d5f38f16d184e36f2408a55281cd658ecbd3ca05cce6d6510a176eca393e26d1"
1523
  dependencies = [
1524
  "bytes 1.5.0",
1525
- "http 0.2.11",
1526
  "pin-project-lite",
1527
  ]
1528
 
@@ -1584,15 +1624,15 @@ dependencies = [
1584
  "futures-channel",
1585
  "futures-core",
1586
  "futures-util",
1587
- "h2 0.3.22",
1588
- "http 0.2.11",
1589
  "http-body 0.4.5",
1590
  "httparse",
1591
  "httpdate",
1592
  "itoa 1.0.9",
1593
  "pin-project-lite",
1594
  "socket2 0.4.10",
1595
- "tokio 1.34.0",
1596
  "tower-service",
1597
  "tracing",
1598
  "want 0.3.1",
@@ -1605,10 +1645,10 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
1605
  checksum = "ec3efd23720e2049821a693cbc7e65ea87c72f1c58ff2f9522ff332b1491e590"
1606
  dependencies = [
1607
  "futures-util",
1608
- "http 0.2.11",
1609
  "hyper 0.14.27",
1610
  "rustls",
1611
- "tokio 1.34.0",
1612
  "tokio-rustls",
1613
  ]
1614
 
@@ -1667,16 +1707,6 @@ dependencies = [
1667
  "hashbrown 0.12.3",
1668
  ]
1669
 
1670
- [[package]]
1671
- name = "indexmap"
1672
- version = "2.1.0"
1673
- source = "registry+https://github.com/rust-lang/crates.io-index"
1674
- checksum = "d530e1a18b1cb4c484e6e34556a0d948706958449fca0cab753d649f2bce3d1f"
1675
- dependencies = [
1676
- "equivalent",
1677
- "hashbrown 0.14.2",
1678
- ]
1679
-
1680
  [[package]]
1681
  name = "iovec"
1682
  version = "0.1.4"
@@ -1788,7 +1818,7 @@ dependencies = [
1788
  "parcel_selectors",
1789
  "paste",
1790
  "pathdiff",
1791
- "smallvec 1.11.2",
1792
  ]
1793
 
1794
  [[package]]
@@ -1910,42 +1940,12 @@ version = "0.1.10"
1910
  source = "registry+https://github.com/rust-lang/crates.io-index"
1911
  checksum = "2532096657941c2fea9c289d370a250971c689d4f143798ff67113ec042024a5"
1912
 
1913
- [[package]]
1914
- name = "maud"
1915
- version = "0.25.0"
1916
- source = "registry+https://github.com/rust-lang/crates.io-index"
1917
- checksum = "b0bab19cef8a7fe1c18a43e881793bfc9d4ea984befec3ae5bd0415abf3ecf00"
1918
- dependencies = [
1919
- "actix-web",
1920
- "futures-util",
1921
- "itoa 1.0.9",
1922
- "maud_macros",
1923
- ]
1924
-
1925
- [[package]]
1926
- name = "maud_macros"
1927
- version = "0.25.0"
1928
- source = "registry+https://github.com/rust-lang/crates.io-index"
1929
- checksum = "0be95d66c3024ffce639216058e5bae17a83ecaf266ffc6e4d060ad447c9eed2"
1930
- dependencies = [
1931
- "proc-macro-error",
1932
- "proc-macro2 1.0.69",
1933
- "quote 1.0.33",
1934
- "syn 1.0.109",
1935
- ]
1936
-
1937
  [[package]]
1938
  name = "maybe-uninit"
1939
  version = "2.0.0"
1940
  source = "registry+https://github.com/rust-lang/crates.io-index"
1941
  checksum = "60302e4db3a61da70c0cb7991976248362f30319e88850c487b9b95bbf059e00"
1942
 
1943
- [[package]]
1944
- name = "md5"
1945
- version = "0.7.0"
1946
- source = "registry+https://github.com/rust-lang/crates.io-index"
1947
- checksum = "490cc448043f947bae3cbee9c203358d62dbee0db12107a74be5c30ccfd09771"
1948
-
1949
  [[package]]
1950
  name = "memchr"
1951
  version = "2.6.4"
@@ -1996,7 +1996,7 @@ dependencies = [
1996
  "crossbeam-utils 0.8.16",
1997
  "dashmap",
1998
  "skeptic",
1999
- "smallvec 1.11.2",
2000
  "tagptr",
2001
  "triomphe",
2002
  ]
@@ -2249,7 +2249,7 @@ dependencies = [
2249
  "phf 0.10.1",
2250
  "phf_codegen 0.10.0",
2251
  "precomputed-hash",
2252
- "smallvec 1.11.2",
2253
  ]
2254
 
2255
  [[package]]
@@ -2297,7 +2297,7 @@ dependencies = [
2297
  "cfg-if 1.0.0",
2298
  "libc",
2299
  "redox_syscall 0.4.1",
2300
- "smallvec 1.11.2",
2301
  "windows-targets",
2302
  ]
2303
 
@@ -2338,6 +2338,51 @@ version = "2.3.0"
2338
  source = "registry+https://github.com/rust-lang/crates.io-index"
2339
  checksum = "9b2a4787296e9989611394c33f193f676704af1686e70b8f8033ab5ba9a35a94"
2340
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2341
  [[package]]
2342
  name = "phf"
2343
  version = "0.7.24"
@@ -2512,30 +2557,6 @@ version = "0.1.1"
2512
  source = "registry+https://github.com/rust-lang/crates.io-index"
2513
  checksum = "925383efa346730478fb4838dbe9137d2a47675ad789c546d150a6e1dd4ab31c"
2514
 
2515
- [[package]]
2516
- name = "proc-macro-error"
2517
- version = "1.0.4"
2518
- source = "registry+https://github.com/rust-lang/crates.io-index"
2519
- checksum = "da25490ff9892aab3fcf7c36f08cfb902dd3e71ca0f9f9517bea02a73a5ce38c"
2520
- dependencies = [
2521
- "proc-macro-error-attr",
2522
- "proc-macro2 1.0.69",
2523
- "quote 1.0.33",
2524
- "syn 1.0.109",
2525
- "version_check",
2526
- ]
2527
-
2528
- [[package]]
2529
- name = "proc-macro-error-attr"
2530
- version = "1.0.4"
2531
- source = "registry+https://github.com/rust-lang/crates.io-index"
2532
- checksum = "a1be40180e52ecc98ad80b184934baf3d0d29f979574e439af5a55274b35f869"
2533
- dependencies = [
2534
- "proc-macro2 1.0.69",
2535
- "quote 1.0.33",
2536
- "version_check",
2537
- ]
2538
-
2539
  [[package]]
2540
  name = "proc-macro2"
2541
  version = "0.4.30"
@@ -2779,7 +2800,7 @@ dependencies = [
2779
  "percent-encoding 2.3.0",
2780
  "pin-project-lite",
2781
  "ryu",
2782
- "tokio 1.34.0",
2783
  "tokio-retry",
2784
  "tokio-util",
2785
  "url 2.4.1",
@@ -2875,8 +2896,8 @@ dependencies = [
2875
  "encoding_rs",
2876
  "futures-core",
2877
  "futures-util",
2878
- "h2 0.3.22",
2879
- "http 0.2.11",
2880
  "http-body 0.4.5",
2881
  "hyper 0.14.27",
2882
  "hyper-rustls",
@@ -2893,7 +2914,7 @@ dependencies = [
2893
  "serde_json",
2894
  "serde_urlencoded 0.7.1",
2895
  "system-configuration",
2896
- "tokio 1.34.0",
2897
  "tokio-rustls",
2898
  "tokio-util",
2899
  "tower-service",
@@ -2964,9 +2985,9 @@ dependencies = [
2964
 
2965
  [[package]]
2966
  name = "rustls"
2967
- version = "0.21.9"
2968
  source = "registry+https://github.com/rust-lang/crates.io-index"
2969
- checksum = "629648aced5775d558af50b2b4c7b02983a04b312126d45eeead26e7caa498b9"
2970
  dependencies = [
2971
  "log",
2972
  "ring",
@@ -2976,9 +2997,9 @@ dependencies = [
2976
 
2977
  [[package]]
2978
  name = "rustls-pemfile"
2979
- version = "1.0.4"
2980
  source = "registry+https://github.com/rust-lang/crates.io-index"
2981
- checksum = "1c74cae0a4cf6ccbbf5f359f08efdf8ee7e1dc532573bf0db71968cb56b1448c"
2982
  dependencies = [
2983
  "base64 0.21.5",
2984
  ]
@@ -3109,7 +3130,7 @@ dependencies = [
3109
  "phf_codegen 0.10.0",
3110
  "precomputed-hash",
3111
  "servo_arc",
3112
- "smallvec 1.11.2",
3113
  ]
3114
 
3115
  [[package]]
@@ -3211,6 +3232,17 @@ dependencies = [
3211
  "digest",
3212
  ]
3213
 
 
 
 
 
 
 
 
 
 
 
 
3214
  [[package]]
3215
  name = "signal-hook-registry"
3216
  version = "1.4.1"
@@ -3267,9 +3299,9 @@ dependencies = [
3267
 
3268
  [[package]]
3269
  name = "smallvec"
3270
- version = "1.11.2"
3271
  source = "registry+https://github.com/rust-lang/crates.io-index"
3272
- checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970"
3273
  dependencies = [
3274
  "serde",
3275
  ]
@@ -3481,6 +3513,26 @@ dependencies = [
3481
  "utf-8",
3482
  ]
3483
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3484
  [[package]]
3485
  name = "thousands"
3486
  version = "0.2.0"
@@ -3573,9 +3625,9 @@ dependencies = [
3573
 
3574
  [[package]]
3575
  name = "tokio"
3576
- version = "1.34.0"
3577
  source = "registry+https://github.com/rust-lang/crates.io-index"
3578
- checksum = "d0c014766411e834f7af5b8f4cf46257aab4036ca95e9d2c144a10f59ad6f5b9"
3579
  dependencies = [
3580
  "backtrace",
3581
  "bytes 1.5.0",
@@ -3634,9 +3686,9 @@ dependencies = [
3634
 
3635
  [[package]]
3636
  name = "tokio-macros"
3637
- version = "2.2.0"
3638
  source = "registry+https://github.com/rust-lang/crates.io-index"
3639
- checksum = "5b8a1e28f2deaa14e508979454cb3a223b10b938b45af148bc0986de36f1923b"
3640
  dependencies = [
3641
  "proc-macro2 1.0.69",
3642
  "quote 1.0.33",
@@ -3670,7 +3722,7 @@ checksum = "7f57eb36ecbe0fc510036adff84824dd3c24bb781e21bfa67b69d556aa85214f"
3670
  dependencies = [
3671
  "pin-project",
3672
  "rand 0.8.5",
3673
- "tokio 1.34.0",
3674
  ]
3675
 
3676
  [[package]]
@@ -3680,7 +3732,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
3680
  checksum = "c28327cf380ac148141087fbfb9de9d7bd4e84ab5d2c28fbc911d753de8a7081"
3681
  dependencies = [
3682
  "rustls",
3683
- "tokio 1.34.0",
3684
  ]
3685
 
3686
  [[package]]
@@ -3746,7 +3798,7 @@ dependencies = [
3746
  "futures-core",
3747
  "futures-sink",
3748
  "pin-project-lite",
3749
- "tokio 1.34.0",
3750
  "tracing",
3751
  ]
3752
 
@@ -3812,6 +3864,12 @@ version = "1.17.0"
3812
  source = "registry+https://github.com/rust-lang/crates.io-index"
3813
  checksum = "42ff0bf0c66b8238c6f3b578df37d0b7848e55df8577b3f74f92a69acceeb825"
3814
 
 
 
 
 
 
 
3815
  [[package]]
3816
  name = "unicase"
3817
  version = "2.7.0"
@@ -4041,7 +4099,7 @@ checksum = "14247bb57be4f377dfb94c72830b8ce8fc6beac03cf4bf7b9732eadd414123fc"
4041
 
4042
  [[package]]
4043
  name = "websurfx"
4044
- version = "1.2.27"
4045
  dependencies = [
4046
  "actix-cors",
4047
  "actix-files",
@@ -4049,16 +4107,16 @@ dependencies = [
4049
  "actix-web",
4050
  "async-once-cell",
4051
  "async-trait",
 
4052
  "criterion",
4053
  "dhat",
4054
  "env_logger",
4055
  "error-stack",
4056
  "fake-useragent",
4057
  "futures 0.3.29",
 
4058
  "lightningcss",
4059
  "log",
4060
- "maud",
4061
- "md5",
4062
  "mimalloc",
4063
  "mini-moka",
4064
  "minify-js",
@@ -4070,9 +4128,9 @@ dependencies = [
4070
  "scraper",
4071
  "serde",
4072
  "serde_json",
4073
- "smallvec 1.11.2",
4074
  "tempfile",
4075
- "tokio 1.34.0",
4076
  ]
4077
 
4078
  [[package]]
@@ -4227,18 +4285,18 @@ dependencies = [
4227
 
4228
  [[package]]
4229
  name = "zerocopy"
4230
- version = "0.7.26"
4231
  source = "registry+https://github.com/rust-lang/crates.io-index"
4232
- checksum = "e97e415490559a91254a2979b4829267a57d2fcd741a98eee8b722fb57289aa0"
4233
  dependencies = [
4234
  "zerocopy-derive",
4235
  ]
4236
 
4237
  [[package]]
4238
  name = "zerocopy-derive"
4239
- version = "0.7.26"
4240
  source = "registry+https://github.com/rust-lang/crates.io-index"
4241
- checksum = "dd7e48ccf166952882ca8bd778a43502c64f33bf94c12ebe2a7f08e5a0f6689f"
4242
  dependencies = [
4243
  "proc-macro2 1.0.69",
4244
  "quote 1.0.33",
 
14
  "futures-sink",
15
  "memchr",
16
  "pin-project-lite",
17
+ "tokio 1.33.0",
18
  "tokio-util",
19
  "tracing",
20
  ]
 
31
  "futures-util",
32
  "log",
33
  "once_cell",
34
+ "smallvec 1.11.1",
35
  ]
36
 
37
  [[package]]
 
87
  "derive_more",
88
  "encoding_rs",
89
  "futures-core",
90
+ "http 0.2.9",
91
  "httparse",
92
  "httpdate",
93
  "itoa 1.0.9",
 
98
  "pin-project-lite",
99
  "rand 0.8.5",
100
  "sha1",
101
+ "smallvec 1.11.1",
102
+ "tokio 1.33.0",
103
  "tokio-util",
104
  "tracing",
105
  ]
 
121
  checksum = "d66ff4d247d2b160861fa2866457e85706833527840e4133f8f49aa423a38799"
122
  dependencies = [
123
  "bytestring",
124
+ "http 0.2.9",
125
  "regex",
126
  "serde",
127
  "tracing",
 
134
  checksum = "28f32d40287d3f402ae0028a9d54bef51af15c8769492826a69d28f81893151d"
135
  dependencies = [
136
  "futures-core",
137
+ "tokio 1.33.0",
138
  ]
139
 
140
  [[package]]
 
150
  "futures-util",
151
  "mio 0.8.9",
152
  "socket2 0.5.5",
153
+ "tokio 1.33.0",
154
  "tracing",
155
  ]
156
 
 
209
  "serde",
210
  "serde_json",
211
  "serde_urlencoded 0.7.1",
212
+ "smallvec 1.11.1",
213
  "socket2 0.5.5",
214
  "time 0.3.30",
215
  "url 2.4.1",
 
323
  source = "registry+https://github.com/rust-lang/crates.io-index"
324
  checksum = "bddcadddf5e9015d310179a59bb28c4d4b9920ad0f11e8e14dbadf654890c9a6"
325
 
326
+ [[package]]
327
+ name = "arrayref"
328
+ version = "0.3.7"
329
+ source = "registry+https://github.com/rust-lang/crates.io-index"
330
+ checksum = "6b4930d2cb77ce62f89ee5d5289b4ac049559b1c45539271f5ed4fdc7db34545"
331
+
332
+ [[package]]
333
+ name = "arrayvec"
334
+ version = "0.7.4"
335
+ source = "registry+https://github.com/rust-lang/crates.io-index"
336
+ checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711"
337
+
338
  [[package]]
339
  name = "askama_escape"
340
  version = "0.10.3"
 
444
  source = "registry+https://github.com/rust-lang/crates.io-index"
445
  checksum = "327762f6e5a765692301e5bb513e0d9fef63be86bbc14528052b1cd3e6f03e07"
446
 
447
+ [[package]]
448
+ name = "blake3"
449
+ version = "1.5.0"
450
+ source = "registry+https://github.com/rust-lang/crates.io-index"
451
+ checksum = "0231f06152bf547e9c2b5194f247cd97aacf6dcd8b15d8e5ec0663f64580da87"
452
+ dependencies = [
453
+ "arrayref",
454
+ "arrayvec",
455
+ "cc",
456
+ "cfg-if 1.0.0",
457
+ "constant_time_eq",
458
+ ]
459
+
460
  [[package]]
461
  name = "block-buffer"
462
  version = "0.10.4"
 
489
 
490
  [[package]]
491
  name = "bstr"
492
+ version = "1.7.0"
493
  source = "registry+https://github.com/rust-lang/crates.io-index"
494
+ checksum = "c79ad7fb2dd38f3dabd76b09c6a5a20c038fc0213ef1e9afd30eb777f120f019"
495
  dependencies = [
496
  "memchr",
497
  "serde",
 
637
 
638
  [[package]]
639
  name = "clap"
640
+ version = "4.4.7"
641
  source = "registry+https://github.com/rust-lang/crates.io-index"
642
+ checksum = "ac495e00dcec98c83465d5ad66c5c4fabd652fd6686e7c6269b117e729a6f17b"
643
  dependencies = [
644
  "clap_builder",
645
  ]
646
 
647
  [[package]]
648
  name = "clap_builder"
649
+ version = "4.4.7"
650
  source = "registry+https://github.com/rust-lang/crates.io-index"
651
+ checksum = "c77ed9a32a62e6ca27175d00d29d05ca32e396ea1eb5fb01d8256b669cec7663"
652
  dependencies = [
653
  "anstyle",
654
  "clap_lex",
 
679
  "futures-core",
680
  "memchr",
681
  "pin-project-lite",
682
+ "tokio 1.33.0",
683
  "tokio-util",
684
  ]
685
 
 
703
  "syn 1.0.109",
704
  ]
705
 
706
+ [[package]]
707
+ name = "constant_time_eq"
708
+ version = "0.3.0"
709
+ source = "registry+https://github.com/rust-lang/crates.io-index"
710
+ checksum = "f7144d30dcf0fafbce74250a3963025d8d52177934239851c917d29f1df280c2"
711
+
712
  [[package]]
713
  name = "convert_case"
714
  version = "0.4.0"
 
909
  "dtoa-short",
910
  "itoa 1.0.9",
911
  "phf 0.11.2",
912
+ "smallvec 1.11.1",
913
  ]
914
 
915
  [[package]]
 
922
  "dtoa-short",
923
  "itoa 1.0.9",
924
  "phf 0.11.2",
925
+ "smallvec 1.11.1",
926
  ]
927
 
928
  [[package]]
 
1055
 
1056
  [[package]]
1057
  name = "env_logger"
1058
+ version = "0.10.0"
1059
  source = "registry+https://github.com/rust-lang/crates.io-index"
1060
+ checksum = "85cdab6a89accf66733ad5a1693a4dcced6aeff64602b634530dd73c1f3ee9f0"
1061
  dependencies = [
1062
  "log",
1063
  ]
 
1069
  checksum = "a2d328fc287c61314c4a61af7cfdcbd7e678e39778488c7cb13ec133ce0f4059"
1070
  dependencies = [
1071
  "fsio",
1072
+ "indexmap",
1073
  ]
1074
 
 
 
 
 
 
 
1075
  [[package]]
1076
  name = "errno"
1077
+ version = "0.3.6"
1078
  source = "registry+https://github.com/rust-lang/crates.io-index"
1079
+ checksum = "7c18ee0ed65a5f1f81cac6b1d213b69c35fa47d4252ad41f1486dbd8226fe36e"
1080
  dependencies = [
1081
  "libc",
1082
  "windows-sys",
 
1395
  "parking_lot 0.12.1",
1396
  "quanta",
1397
  "rand 0.8.5",
1398
+ "smallvec 1.11.1",
1399
  ]
1400
 
1401
  [[package]]
 
1409
  "fnv",
1410
  "futures 0.1.31",
1411
  "http 0.1.21",
1412
+ "indexmap",
1413
  "log",
1414
  "slab",
1415
  "string",
 
1418
 
1419
  [[package]]
1420
  name = "h2"
1421
+ version = "0.3.21"
1422
  source = "registry+https://github.com/rust-lang/crates.io-index"
1423
+ checksum = "91fc23aa11be92976ef4729127f1a74adf36d8436f7816b185d18df956790833"
1424
  dependencies = [
1425
  "bytes 1.5.0",
1426
  "fnv",
1427
  "futures-core",
1428
  "futures-sink",
1429
  "futures-util",
1430
+ "http 0.2.9",
1431
+ "indexmap",
1432
  "slab",
1433
+ "tokio 1.33.0",
1434
  "tokio-util",
1435
  "tracing",
1436
  ]
 
1441
  source = "registry+https://github.com/rust-lang/crates.io-index"
1442
  checksum = "eabb4a44450da02c90444cf74558da904edde8fb4e9035a9a6a4e15445af0bd7"
1443
 
1444
+ [[package]]
1445
+ name = "handlebars"
1446
+ version = "4.4.0"
1447
+ source = "registry+https://github.com/rust-lang/crates.io-index"
1448
+ checksum = "c39b3bc2a8f715298032cf5087e58573809374b08160aa7d750582bdb82d2683"
1449
+ dependencies = [
1450
+ "log",
1451
+ "pest",
1452
+ "pest_derive",
1453
+ "serde",
1454
+ "serde_json",
1455
+ "thiserror",
1456
+ "walkdir",
1457
+ ]
1458
+
1459
  [[package]]
1460
  name = "hashbrown"
1461
  version = "0.12.3"
 
1534
 
1535
  [[package]]
1536
  name = "http"
1537
+ version = "0.2.9"
1538
  source = "registry+https://github.com/rust-lang/crates.io-index"
1539
+ checksum = "bd6effc99afb63425aff9b05836f029929e345a6148a14b7ecd5ab67af944482"
1540
  dependencies = [
1541
  "bytes 1.5.0",
1542
  "fnv",
 
1562
  checksum = "d5f38f16d184e36f2408a55281cd658ecbd3ca05cce6d6510a176eca393e26d1"
1563
  dependencies = [
1564
  "bytes 1.5.0",
1565
+ "http 0.2.9",
1566
  "pin-project-lite",
1567
  ]
1568
 
 
1624
  "futures-channel",
1625
  "futures-core",
1626
  "futures-util",
1627
+ "h2 0.3.21",
1628
+ "http 0.2.9",
1629
  "http-body 0.4.5",
1630
  "httparse",
1631
  "httpdate",
1632
  "itoa 1.0.9",
1633
  "pin-project-lite",
1634
  "socket2 0.4.10",
1635
+ "tokio 1.33.0",
1636
  "tower-service",
1637
  "tracing",
1638
  "want 0.3.1",
 
1645
  checksum = "ec3efd23720e2049821a693cbc7e65ea87c72f1c58ff2f9522ff332b1491e590"
1646
  dependencies = [
1647
  "futures-util",
1648
+ "http 0.2.9",
1649
  "hyper 0.14.27",
1650
  "rustls",
1651
+ "tokio 1.33.0",
1652
  "tokio-rustls",
1653
  ]
1654
 
 
1707
  "hashbrown 0.12.3",
1708
  ]
1709
 
 
 
 
 
 
 
 
 
 
 
1710
  [[package]]
1711
  name = "iovec"
1712
  version = "0.1.4"
 
1818
  "parcel_selectors",
1819
  "paste",
1820
  "pathdiff",
1821
+ "smallvec 1.11.1",
1822
  ]
1823
 
1824
  [[package]]
 
1940
  source = "registry+https://github.com/rust-lang/crates.io-index"
1941
  checksum = "2532096657941c2fea9c289d370a250971c689d4f143798ff67113ec042024a5"
1942
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1943
  [[package]]
1944
  name = "maybe-uninit"
1945
  version = "2.0.0"
1946
  source = "registry+https://github.com/rust-lang/crates.io-index"
1947
  checksum = "60302e4db3a61da70c0cb7991976248362f30319e88850c487b9b95bbf059e00"
1948
 
 
 
 
 
 
 
1949
  [[package]]
1950
  name = "memchr"
1951
  version = "2.6.4"
 
1996
  "crossbeam-utils 0.8.16",
1997
  "dashmap",
1998
  "skeptic",
1999
+ "smallvec 1.11.1",
2000
  "tagptr",
2001
  "triomphe",
2002
  ]
 
2249
  "phf 0.10.1",
2250
  "phf_codegen 0.10.0",
2251
  "precomputed-hash",
2252
+ "smallvec 1.11.1",
2253
  ]
2254
 
2255
  [[package]]
 
2297
  "cfg-if 1.0.0",
2298
  "libc",
2299
  "redox_syscall 0.4.1",
2300
+ "smallvec 1.11.1",
2301
  "windows-targets",
2302
  ]
2303
 
 
2338
  source = "registry+https://github.com/rust-lang/crates.io-index"
2339
  checksum = "9b2a4787296e9989611394c33f193f676704af1686e70b8f8033ab5ba9a35a94"
2340
 
2341
+ [[package]]
2342
+ name = "pest"
2343
+ version = "2.7.5"
2344
+ source = "registry+https://github.com/rust-lang/crates.io-index"
2345
+ checksum = "ae9cee2a55a544be8b89dc6848072af97a20f2422603c10865be2a42b580fff5"
2346
+ dependencies = [
2347
+ "memchr",
2348
+ "thiserror",
2349
+ "ucd-trie",
2350
+ ]
2351
+
2352
+ [[package]]
2353
+ name = "pest_derive"
2354
+ version = "2.7.5"
2355
+ source = "registry+https://github.com/rust-lang/crates.io-index"
2356
+ checksum = "81d78524685f5ef2a3b3bd1cafbc9fcabb036253d9b1463e726a91cd16e2dfc2"
2357
+ dependencies = [
2358
+ "pest",
2359
+ "pest_generator",
2360
+ ]
2361
+
2362
+ [[package]]
2363
+ name = "pest_generator"
2364
+ version = "2.7.5"
2365
+ source = "registry+https://github.com/rust-lang/crates.io-index"
2366
+ checksum = "68bd1206e71118b5356dae5ddc61c8b11e28b09ef6a31acbd15ea48a28e0c227"
2367
+ dependencies = [
2368
+ "pest",
2369
+ "pest_meta",
2370
+ "proc-macro2 1.0.69",
2371
+ "quote 1.0.33",
2372
+ "syn 2.0.39",
2373
+ ]
2374
+
2375
+ [[package]]
2376
+ name = "pest_meta"
2377
+ version = "2.7.5"
2378
+ source = "registry+https://github.com/rust-lang/crates.io-index"
2379
+ checksum = "7c747191d4ad9e4a4ab9c8798f1e82a39affe7ef9648390b7e5548d18e099de6"
2380
+ dependencies = [
2381
+ "once_cell",
2382
+ "pest",
2383
+ "sha2",
2384
+ ]
2385
+
2386
  [[package]]
2387
  name = "phf"
2388
  version = "0.7.24"
 
2557
  source = "registry+https://github.com/rust-lang/crates.io-index"
2558
  checksum = "925383efa346730478fb4838dbe9137d2a47675ad789c546d150a6e1dd4ab31c"
2559
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2560
  [[package]]
2561
  name = "proc-macro2"
2562
  version = "0.4.30"
 
2800
  "percent-encoding 2.3.0",
2801
  "pin-project-lite",
2802
  "ryu",
2803
+ "tokio 1.33.0",
2804
  "tokio-retry",
2805
  "tokio-util",
2806
  "url 2.4.1",
 
2896
  "encoding_rs",
2897
  "futures-core",
2898
  "futures-util",
2899
+ "h2 0.3.21",
2900
+ "http 0.2.9",
2901
  "http-body 0.4.5",
2902
  "hyper 0.14.27",
2903
  "hyper-rustls",
 
2914
  "serde_json",
2915
  "serde_urlencoded 0.7.1",
2916
  "system-configuration",
2917
+ "tokio 1.33.0",
2918
  "tokio-rustls",
2919
  "tokio-util",
2920
  "tower-service",
 
2985
 
2986
  [[package]]
2987
  name = "rustls"
2988
+ version = "0.21.8"
2989
  source = "registry+https://github.com/rust-lang/crates.io-index"
2990
+ checksum = "446e14c5cda4f3f30fe71863c34ec70f5ac79d6087097ad0bb433e1be5edf04c"
2991
  dependencies = [
2992
  "log",
2993
  "ring",
 
2997
 
2998
  [[package]]
2999
  name = "rustls-pemfile"
3000
+ version = "1.0.3"
3001
  source = "registry+https://github.com/rust-lang/crates.io-index"
3002
+ checksum = "2d3987094b1d07b653b7dfdc3f70ce9a1da9c51ac18c1b06b662e4f9a0e9f4b2"
3003
  dependencies = [
3004
  "base64 0.21.5",
3005
  ]
 
3130
  "phf_codegen 0.10.0",
3131
  "precomputed-hash",
3132
  "servo_arc",
3133
+ "smallvec 1.11.1",
3134
  ]
3135
 
3136
  [[package]]
 
3232
  "digest",
3233
  ]
3234
 
3235
+ [[package]]
3236
+ name = "sha2"
3237
+ version = "0.10.8"
3238
+ source = "registry+https://github.com/rust-lang/crates.io-index"
3239
+ checksum = "793db75ad2bcafc3ffa7c68b215fee268f537982cd901d132f89c6343f3a3dc8"
3240
+ dependencies = [
3241
+ "cfg-if 1.0.0",
3242
+ "cpufeatures",
3243
+ "digest",
3244
+ ]
3245
+
3246
  [[package]]
3247
  name = "signal-hook-registry"
3248
  version = "1.4.1"
 
3299
 
3300
  [[package]]
3301
  name = "smallvec"
3302
+ version = "1.11.1"
3303
  source = "registry+https://github.com/rust-lang/crates.io-index"
3304
+ checksum = "942b4a808e05215192e39f4ab80813e599068285906cc91aa64f923db842bd5a"
3305
  dependencies = [
3306
  "serde",
3307
  ]
 
3513
  "utf-8",
3514
  ]
3515
 
3516
+ [[package]]
3517
+ name = "thiserror"
3518
+ version = "1.0.50"
3519
+ source = "registry+https://github.com/rust-lang/crates.io-index"
3520
+ checksum = "f9a7210f5c9a7156bb50aa36aed4c95afb51df0df00713949448cf9e97d382d2"
3521
+ dependencies = [
3522
+ "thiserror-impl",
3523
+ ]
3524
+
3525
+ [[package]]
3526
+ name = "thiserror-impl"
3527
+ version = "1.0.50"
3528
+ source = "registry+https://github.com/rust-lang/crates.io-index"
3529
+ checksum = "266b2e40bc00e5a6c09c3584011e08b06f123c00362c92b975ba9843aaaa14b8"
3530
+ dependencies = [
3531
+ "proc-macro2 1.0.69",
3532
+ "quote 1.0.33",
3533
+ "syn 2.0.39",
3534
+ ]
3535
+
3536
  [[package]]
3537
  name = "thousands"
3538
  version = "0.2.0"
 
3625
 
3626
  [[package]]
3627
  name = "tokio"
3628
+ version = "1.33.0"
3629
  source = "registry+https://github.com/rust-lang/crates.io-index"
3630
+ checksum = "4f38200e3ef7995e5ef13baec2f432a6da0aa9ac495b2c0e8f3b7eec2c92d653"
3631
  dependencies = [
3632
  "backtrace",
3633
  "bytes 1.5.0",
 
3686
 
3687
  [[package]]
3688
  name = "tokio-macros"
3689
+ version = "2.1.0"
3690
  source = "registry+https://github.com/rust-lang/crates.io-index"
3691
+ checksum = "630bdcf245f78637c13ec01ffae6187cca34625e8c63150d424b59e55af2675e"
3692
  dependencies = [
3693
  "proc-macro2 1.0.69",
3694
  "quote 1.0.33",
 
3722
  dependencies = [
3723
  "pin-project",
3724
  "rand 0.8.5",
3725
+ "tokio 1.33.0",
3726
  ]
3727
 
3728
  [[package]]
 
3732
  checksum = "c28327cf380ac148141087fbfb9de9d7bd4e84ab5d2c28fbc911d753de8a7081"
3733
  dependencies = [
3734
  "rustls",
3735
+ "tokio 1.33.0",
3736
  ]
3737
 
3738
  [[package]]
 
3798
  "futures-core",
3799
  "futures-sink",
3800
  "pin-project-lite",
3801
+ "tokio 1.33.0",
3802
  "tracing",
3803
  ]
3804
 
 
3864
  source = "registry+https://github.com/rust-lang/crates.io-index"
3865
  checksum = "42ff0bf0c66b8238c6f3b578df37d0b7848e55df8577b3f74f92a69acceeb825"
3866
 
3867
+ [[package]]
3868
+ name = "ucd-trie"
3869
+ version = "0.1.6"
3870
+ source = "registry+https://github.com/rust-lang/crates.io-index"
3871
+ checksum = "ed646292ffc8188ef8ea4d1e0e0150fb15a5c2e12ad9b8fc191ae7a8a7f3c4b9"
3872
+
3873
  [[package]]
3874
  name = "unicase"
3875
  version = "2.7.0"
 
4099
 
4100
  [[package]]
4101
  name = "websurfx"
4102
+ version = "1.2.28"
4103
  dependencies = [
4104
  "actix-cors",
4105
  "actix-files",
 
4107
  "actix-web",
4108
  "async-once-cell",
4109
  "async-trait",
4110
+ "blake3",
4111
  "criterion",
4112
  "dhat",
4113
  "env_logger",
4114
  "error-stack",
4115
  "fake-useragent",
4116
  "futures 0.3.29",
4117
+ "handlebars",
4118
  "lightningcss",
4119
  "log",
 
 
4120
  "mimalloc",
4121
  "mini-moka",
4122
  "minify-js",
 
4128
  "scraper",
4129
  "serde",
4130
  "serde_json",
4131
+ "smallvec 1.11.1",
4132
  "tempfile",
4133
+ "tokio 1.33.0",
4134
  ]
4135
 
4136
  [[package]]
 
4285
 
4286
  [[package]]
4287
  name = "zerocopy"
4288
+ version = "0.7.25"
4289
  source = "registry+https://github.com/rust-lang/crates.io-index"
4290
+ checksum = "8cd369a67c0edfef15010f980c3cbe45d7f651deac2cd67ce097cd801de16557"
4291
  dependencies = [
4292
  "zerocopy-derive",
4293
  ]
4294
 
4295
  [[package]]
4296
  name = "zerocopy-derive"
4297
+ version = "0.7.25"
4298
  source = "registry+https://github.com/rust-lang/crates.io-index"
4299
+ checksum = "c2f140bda219a26ccc0cdb03dba58af72590c53b22642577d88a927bc5c87d6b"
4300
  dependencies = [
4301
  "proc-macro2 1.0.69",
4302
  "quote 1.0.33",
Cargo.toml CHANGED
@@ -1,6 +1,6 @@
1
  [package]
2
  name = "websurfx"
3
- version = "1.2.27"
4
  edition = "2021"
5
  description = "An open-source alternative to Searx that provides clean, ad-free, and organic results with incredible speed while keeping privacy and security in mind."
6
  repository = "https://github.com/neon-mmd/websurfx"
@@ -27,7 +27,7 @@ env_logger = {version="0.10.0", default-features=false}
27
  log = {version="0.4.20", default-features=false}
28
  mlua = {version="0.9.1", features=["luajit", "vendored"], default-features=false}
29
  redis = {version="0.23.3", features=["tokio-comp","connection-manager"], default-features = false, optional = true}
30
- md5 = {version="0.7.0", default-features=false}
31
  error-stack = {version="0.4.0", default-features=false, features=["std"]}
32
  async-trait = {version="0.1.73", default-features=false}
33
  regex = {version="1.9.4", features=["perf"], default-features = false}
 
1
  [package]
2
  name = "websurfx"
3
+ version = "1.2.28"
4
  edition = "2021"
5
  description = "An open-source alternative to Searx that provides clean, ad-free, and organic results with incredible speed while keeping privacy and security in mind."
6
  repository = "https://github.com/neon-mmd/websurfx"
 
27
  log = {version="0.4.20", default-features=false}
28
  mlua = {version="0.9.1", features=["luajit", "vendored"], default-features=false}
29
  redis = {version="0.23.3", features=["tokio-comp","connection-manager"], default-features = false, optional = true}
30
+ blake3 = {version="1.5.0", default-features=false}
31
  error-stack = {version="0.4.0", default-features=false, features=["std"]}
32
  async-trait = {version="0.1.73", default-features=false}
33
  regex = {version="1.9.4", features=["perf"], default-features = false}
src/cache/redis_cacher.rs CHANGED
@@ -1,9 +1,9 @@
1
  //! This module provides the functionality to cache the aggregated results fetched and aggregated
2
  //! from the upstream search engines in a json format.
3
 
 
4
  use error_stack::Report;
5
  use futures::future::try_join_all;
6
- use md5::compute;
7
  use redis::{aio::ConnectionManager, AsyncCommands, Client, RedisError};
8
 
9
  use super::error::CacheError;
@@ -59,7 +59,7 @@ impl RedisCache {
59
  ///
60
  /// * `url` - It takes an url as string.
61
  fn hash_url(&self, url: &str) -> String {
62
- format!("{:?}", compute(url))
63
  }
64
 
65
  /// A function which fetches the cached json results as json string from the redis server.
 
1
  //! This module provides the functionality to cache the aggregated results fetched and aggregated
2
  //! from the upstream search engines in a json format.
3
 
4
+ use blake3::hash;
5
  use error_stack::Report;
6
  use futures::future::try_join_all;
 
7
  use redis::{aio::ConnectionManager, AsyncCommands, Client, RedisError};
8
 
9
  use super::error::CacheError;
 
59
  ///
60
  /// * `url` - It takes an url as string.
61
  fn hash_url(&self, url: &str) -> String {
62
+ format!("{:?}", blake3::hash(url.as_bytes()))
63
  }
64
 
65
  /// A function which fetches the cached json results as json string from the redis server.