mihari 5.4.8 → 5.5.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (90) hide show
  1. checksums.yaml +4 -4
  2. data/docs/analyzers/binaryedge.md +2 -2
  3. data/docs/analyzers/censys.md +3 -3
  4. data/docs/analyzers/circl.md +3 -3
  5. data/docs/analyzers/crtsh.md +2 -2
  6. data/docs/analyzers/dnstwister.md +1 -1
  7. data/docs/analyzers/feed.md +7 -7
  8. data/docs/analyzers/greynoise.md +2 -2
  9. data/docs/analyzers/hunterhow.md +4 -4
  10. data/docs/analyzers/index.md +13 -8
  11. data/docs/analyzers/onyphe.md +2 -2
  12. data/docs/analyzers/otx.md +2 -2
  13. data/docs/analyzers/passivetotal.md +3 -3
  14. data/docs/analyzers/pulsedive.md +2 -2
  15. data/docs/analyzers/securitytrails.md +2 -2
  16. data/docs/analyzers/shodan.md +2 -2
  17. data/docs/analyzers/urlscan.md +2 -2
  18. data/docs/analyzers/virustotal.md +2 -2
  19. data/docs/analyzers/virustotal_intelligence.md +2 -2
  20. data/docs/analyzers/zoomeye.md +3 -3
  21. data/docs/emitters/hive.md +3 -3
  22. data/docs/emitters/index.md +29 -0
  23. data/docs/emitters/misp.md +2 -2
  24. data/docs/emitters/slack.md +2 -2
  25. data/docs/emitters/webhook.md +4 -4
  26. data/docs/enrichers/index.md +29 -0
  27. data/docs/enrichers/ipinfo.md +7 -0
  28. data/docs/index.md +0 -2
  29. data/docs/installation.md +1 -1
  30. data/docs/rule.md +11 -11
  31. data/frontend/package-lock.json +294 -2772
  32. data/frontend/package.json +10 -10
  33. data/lib/mihari/analyzers/base.rb +15 -8
  34. data/lib/mihari/analyzers/binaryedge.rb +5 -1
  35. data/lib/mihari/analyzers/censys.rb +6 -1
  36. data/lib/mihari/analyzers/greynoise.rb +5 -1
  37. data/lib/mihari/analyzers/hunterhow.rb +5 -1
  38. data/lib/mihari/analyzers/onyphe.rb +5 -1
  39. data/lib/mihari/analyzers/rule.rb +43 -7
  40. data/lib/mihari/analyzers/shodan.rb +5 -1
  41. data/lib/mihari/analyzers/urlscan.rb +5 -1
  42. data/lib/mihari/analyzers/virustotal_intelligence.rb +5 -1
  43. data/lib/mihari/analyzers/zoomeye.rb +5 -1
  44. data/lib/mihari/clients/base.rb +7 -7
  45. data/lib/mihari/clients/binaryedge.rb +10 -4
  46. data/lib/mihari/clients/censys.rb +11 -4
  47. data/lib/mihari/clients/greynoise.rb +10 -4
  48. data/lib/mihari/clients/hunterhow.rb +10 -4
  49. data/lib/mihari/clients/misp.rb +3 -2
  50. data/lib/mihari/clients/onyphe.rb +10 -4
  51. data/lib/mihari/clients/shodan.rb +10 -4
  52. data/lib/mihari/clients/the_hive.rb +3 -2
  53. data/lib/mihari/clients/urlscan.rb +9 -3
  54. data/lib/mihari/clients/virustotal.rb +10 -4
  55. data/lib/mihari/clients/zoomeye.rb +11 -5
  56. data/lib/mihari/config.rb +8 -0
  57. data/lib/mihari/emitters/base.rb +49 -12
  58. data/lib/mihari/emitters/misp.rb +7 -6
  59. data/lib/mihari/emitters/slack.rb +24 -6
  60. data/lib/mihari/emitters/the_hive.rb +8 -7
  61. data/lib/mihari/emitters/webhook.rb +31 -29
  62. data/lib/mihari/enrichers/base.rb +53 -16
  63. data/lib/mihari/enrichers/google_public_dns.rb +33 -42
  64. data/lib/mihari/enrichers/ipinfo.rb +32 -34
  65. data/lib/mihari/enrichers/shodan.rb +18 -26
  66. data/lib/mihari/enrichers/whois.rb +121 -111
  67. data/lib/mihari/http.rb +3 -1
  68. data/lib/mihari/mixins/retriable.rb +4 -2
  69. data/lib/mihari/models/artifact.rb +37 -23
  70. data/lib/mihari/models/autonomous_system.rb +3 -2
  71. data/lib/mihari/models/cpe.rb +3 -2
  72. data/lib/mihari/models/dns.rb +3 -2
  73. data/lib/mihari/models/geolocation.rb +3 -2
  74. data/lib/mihari/models/port.rb +3 -2
  75. data/lib/mihari/models/reverse_dns.rb +3 -2
  76. data/lib/mihari/models/whois.rb +4 -3
  77. data/lib/mihari/schemas/analyzer.rb +2 -1
  78. data/lib/mihari/schemas/emitter.rb +39 -25
  79. data/lib/mihari/schemas/enricher.rb +28 -2
  80. data/lib/mihari/schemas/rule.rb +6 -2
  81. data/lib/mihari/version.rb +1 -1
  82. data/lib/mihari/web/endpoints/ip_addresses.rb +1 -1
  83. data/lib/mihari/web/public/assets/index-b5d817a3.js +1749 -0
  84. data/lib/mihari/web/public/index.html +1 -1
  85. data/lib/mihari/web/public/redoc-static.html +400 -400
  86. data/mihari.gemspec +2 -2
  87. data/mkdocs.yml +8 -6
  88. data/requirements.txt +1 -1
  89. metadata +7 -7
  90. data/lib/mihari/web/public/assets/index-a92abd57.js +0 -1740
@@ -15,7 +15,7 @@ module Mihari
15
15
  get "/:ip", requirements: { ip: %r{[^/]+} } do
16
16
  ip = params[:ip].to_s
17
17
 
18
- data = Enrichers::IPInfo.query(ip)
18
+ data = Enrichers::IPInfo.new.query(ip)
19
19
  error!({ message: "IP:#{ip} is not found" }, 404) if data.nil?
20
20
 
21
21
  present data, with: Entities::IPAddress