moriarty-project 0.1.6__py3-none-any.whl
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.
- moriarty/__init__.py +5 -0
- moriarty/adapters/__init__.py +0 -0
- moriarty/agent/__init__.py +0 -0
- moriarty/assets/modules/.gitkeep +0 -0
- moriarty/assets/modules/asia/douban.yaml +19 -0
- moriarty/assets/modules/asia/kakao.yaml +19 -0
- moriarty/assets/modules/asia/line.yaml +19 -0
- moriarty/assets/modules/asia/mixi.yaml +19 -0
- moriarty/assets/modules/asia/naver.yaml +19 -0
- moriarty/assets/modules/asia/qq.yaml +19 -0
- moriarty/assets/modules/asia/vk.yaml +19 -0
- moriarty/assets/modules/asia/wechat.yaml +19 -0
- moriarty/assets/modules/asia/weibo.yaml +19 -0
- moriarty/assets/modules/asia/xiaohongshu.yaml +19 -0
- moriarty/assets/modules/behance.yaml +47 -0
- moriarty/assets/modules/business/crunchbase.yaml +27 -0
- moriarty/assets/modules/business/fiverr.yaml +32 -0
- moriarty/assets/modules/business/freelancer.yaml +27 -0
- moriarty/assets/modules/business/glassdoor.yaml +27 -0
- moriarty/assets/modules/business/guru.yaml +26 -0
- moriarty/assets/modules/business/indeed.yaml +25 -0
- moriarty/assets/modules/business/monster.yaml +25 -0
- moriarty/assets/modules/business/peopleperhour.yaml +26 -0
- moriarty/assets/modules/business/toptal.yaml +28 -0
- moriarty/assets/modules/business/upwork.yaml +27 -0
- moriarty/assets/modules/business/ziprecruiter.yaml +25 -0
- moriarty/assets/modules/content/buymeacoffee.yaml +27 -0
- moriarty/assets/modules/content/gumroad.yaml +27 -0
- moriarty/assets/modules/content/ko-fi.yaml +32 -0
- moriarty/assets/modules/content/onlyfans.yaml +27 -0
- moriarty/assets/modules/content/patreon.yaml +33 -0
- moriarty/assets/modules/content/substack.yaml +32 -0
- moriarty/assets/modules/creative/500px.yaml +31 -0
- moriarty/assets/modules/creative/artstation.yaml +33 -0
- moriarty/assets/modules/creative/deviantart.yaml +32 -0
- moriarty/assets/modules/creative/flickr.yaml +31 -0
- moriarty/assets/modules/creative/pexels.yaml +26 -0
- moriarty/assets/modules/creative/unsplash.yaml +26 -0
- moriarty/assets/modules/creative/vimeo.yaml +31 -0
- moriarty/assets/modules/crypto/binance.yaml +27 -0
- moriarty/assets/modules/crypto/bitcointalk.yaml +33 -0
- moriarty/assets/modules/crypto/coinbase.yaml +26 -0
- moriarty/assets/modules/crypto/etherscan.yaml +32 -0
- moriarty/assets/modules/crypto/foundation.yaml +28 -0
- moriarty/assets/modules/crypto/kraken.yaml +27 -0
- moriarty/assets/modules/crypto/mirror.yaml +27 -0
- moriarty/assets/modules/crypto/niftygateway.yaml +26 -0
- moriarty/assets/modules/crypto/opensea.yaml +32 -0
- moriarty/assets/modules/crypto/rarible.yaml +27 -0
- moriarty/assets/modules/crypto/superrare.yaml +29 -0
- moriarty/assets/modules/dating/bumble.yaml +25 -0
- moriarty/assets/modules/dating/grindr.yaml +27 -0
- moriarty/assets/modules/dating/happn.yaml +25 -0
- moriarty/assets/modules/dating/her.yaml +27 -0
- moriarty/assets/modules/dating/hinge.yaml +25 -0
- moriarty/assets/modules/dating/match.yaml +25 -0
- moriarty/assets/modules/dating/meetme.yaml +27 -0
- moriarty/assets/modules/dating/okcupid.yaml +25 -0
- moriarty/assets/modules/dating/pof.yaml +25 -0
- moriarty/assets/modules/dating/tinder.yaml +25 -0
- moriarty/assets/modules/dating-nsfw/adultfriendfinder.yaml +28 -0
- moriarty/assets/modules/dating-nsfw/ashley-madison.yaml +26 -0
- moriarty/assets/modules/design/adobe-portfolio.yaml +27 -0
- moriarty/assets/modules/design/carbonmade.yaml +27 -0
- moriarty/assets/modules/design/cgsociety.yaml +27 -0
- moriarty/assets/modules/design/coroflot.yaml +27 -0
- moriarty/assets/modules/design/figma.yaml +27 -0
- moriarty/assets/modules/design/sketch.yaml +26 -0
- moriarty/assets/modules/dev/bitbucket.yaml +35 -0
- moriarty/assets/modules/dev/codeforces.yaml +32 -0
- moriarty/assets/modules/dev/codepen.yaml +34 -0
- moriarty/assets/modules/dev/hackerone.yaml +32 -0
- moriarty/assets/modules/dev/hackthebox.yaml +27 -0
- moriarty/assets/modules/dev/huggingface.yaml +27 -0
- moriarty/assets/modules/dev/kaggle.yaml +32 -0
- moriarty/assets/modules/dev/leetcode.yaml +32 -0
- moriarty/assets/modules/dev/replit.yaml +31 -0
- moriarty/assets/modules/dribbble.yaml +53 -0
- moriarty/assets/modules/ecommerce/etsy.yaml +32 -0
- moriarty/assets/modules/education/duolingo.yaml +32 -0
- moriarty/assets/modules/education/edx.yaml +26 -0
- moriarty/assets/modules/education/khanacademy.yaml +26 -0
- moriarty/assets/modules/education/lynda.yaml +27 -0
- moriarty/assets/modules/education/memrise.yaml +27 -0
- moriarty/assets/modules/education/pluralsight.yaml +27 -0
- moriarty/assets/modules/education/skillshare.yaml +27 -0
- moriarty/assets/modules/education/udacity.yaml +27 -0
- moriarty/assets/modules/email/github_email.yaml +40 -0
- moriarty/assets/modules/email/gravatar.yaml +23 -0
- moriarty/assets/modules/europe/badoo.yaml +19 -0
- moriarty/assets/modules/europe/lovoo.yaml +19 -0
- moriarty/assets/modules/europe/myspace.yaml +19 -0
- moriarty/assets/modules/europe/netlog.yaml +19 -0
- moriarty/assets/modules/europe/ok.yaml +19 -0
- moriarty/assets/modules/europe/skyrock.yaml +19 -0
- moriarty/assets/modules/europe/studivz.yaml +19 -0
- moriarty/assets/modules/europe/tuenti.yaml +19 -0
- moriarty/assets/modules/europe/viadeo.yaml +19 -0
- moriarty/assets/modules/europe/xing.yaml +19 -0
- moriarty/assets/modules/fitness/fitbit.yaml +27 -0
- moriarty/assets/modules/fitness/garmin.yaml +27 -0
- moriarty/assets/modules/fitness/myfitnesspal.yaml +27 -0
- moriarty/assets/modules/fitness/strava.yaml +33 -0
- moriarty/assets/modules/fitness/zwift.yaml +28 -0
- moriarty/assets/modules/food/allrecipes.yaml +27 -0
- moriarty/assets/modules/food/tasty.yaml +27 -0
- moriarty/assets/modules/food/yelp.yaml +32 -0
- moriarty/assets/modules/food/zomato.yaml +28 -0
- moriarty/assets/modules/forums/4chan.yaml +26 -0
- moriarty/assets/modules/forums/8kun.yaml +26 -0
- moriarty/assets/modules/forums/9gag.yaml +26 -0
- moriarty/assets/modules/forums/discourse.yaml +26 -0
- moriarty/assets/modules/forums/disqus.yaml +31 -0
- moriarty/assets/modules/forums/hackernews.yaml +32 -0
- moriarty/assets/modules/forums/launchpad.yaml +27 -0
- moriarty/assets/modules/forums/phpbb.yaml +25 -0
- moriarty/assets/modules/forums/quora.yaml +32 -0
- moriarty/assets/modules/forums/serverfault.yaml +27 -0
- moriarty/assets/modules/forums/slashdot.yaml +28 -0
- moriarty/assets/modules/forums/stackexchange.yaml +32 -0
- moriarty/assets/modules/forums/superuser.yaml +27 -0
- moriarty/assets/modules/forums/vbulletin.yaml +25 -0
- moriarty/assets/modules/forums/xenforo.yaml +25 -0
- moriarty/assets/modules/forums-nsfw/kiwifarms.yaml +25 -0
- moriarty/assets/modules/forums-nsfw/lolcow.yaml +26 -0
- moriarty/assets/modules/gaming/apextracker.yaml +27 -0
- moriarty/assets/modules/gaming/battlenet.yaml +26 -0
- moriarty/assets/modules/gaming/chess.yaml +30 -0
- moriarty/assets/modules/gaming/discord-public.yaml +27 -0
- moriarty/assets/modules/gaming/dotabuff.yaml +32 -0
- moriarty/assets/modules/gaming/epicgames.yaml +25 -0
- moriarty/assets/modules/gaming/faceit.yaml +33 -0
- moriarty/assets/modules/gaming/fortnitetracker.yaml +32 -0
- moriarty/assets/modules/gaming/gog.yaml +26 -0
- moriarty/assets/modules/gaming/itch.yaml +32 -0
- moriarty/assets/modules/gaming/kongregate.yaml +25 -0
- moriarty/assets/modules/gaming/minecraft.yaml +31 -0
- moriarty/assets/modules/gaming/opgg.yaml +32 -0
- moriarty/assets/modules/gaming/origin.yaml +26 -0
- moriarty/assets/modules/gaming/playstation.yaml +30 -0
- moriarty/assets/modules/gaming/roblox.yaml +31 -0
- moriarty/assets/modules/gaming/xbox.yaml +25 -0
- moriarty/assets/modules/github.yaml +68 -0
- moriarty/assets/modules/gitlab.yaml +60 -0
- moriarty/assets/modules/instagram.yaml +48 -0
- moriarty/assets/modules/latam/fotolog.yaml +27 -0
- moriarty/assets/modules/latam/orkut.yaml +26 -0
- moriarty/assets/modules/latam/taringa.yaml +27 -0
- moriarty/assets/modules/learning/coursera.yaml +26 -0
- moriarty/assets/modules/learning/udemy.yaml +26 -0
- moriarty/assets/modules/linkedin.yaml +40 -0
- moriarty/assets/modules/marketplaces/depop.yaml +28 -0
- moriarty/assets/modules/marketplaces/ebay.yaml +32 -0
- moriarty/assets/modules/marketplaces/grailed.yaml +27 -0
- moriarty/assets/modules/marketplaces/mercari.yaml +26 -0
- moriarty/assets/modules/marketplaces/poshmark.yaml +27 -0
- moriarty/assets/modules/marketplaces/reverb.yaml +27 -0
- moriarty/assets/modules/marketplaces/vinted.yaml +28 -0
- moriarty/assets/modules/medium.yaml +44 -0
- moriarty/assets/modules/music/audiomack.yaml +26 -0
- moriarty/assets/modules/music/bandcamp.yaml +30 -0
- moriarty/assets/modules/music/beatport.yaml +28 -0
- moriarty/assets/modules/music/deezer.yaml +26 -0
- moriarty/assets/modules/music/discogs.yaml +32 -0
- moriarty/assets/modules/music/genius.yaml +26 -0
- moriarty/assets/modules/music/lastfm.yaml +30 -0
- moriarty/assets/modules/music/mixcloud.yaml +26 -0
- moriarty/assets/modules/music/reverbnation.yaml +31 -0
- moriarty/assets/modules/music/soundcloud.yaml +31 -0
- moriarty/assets/modules/music/spotify.yaml +26 -0
- moriarty/assets/modules/music/tidal.yaml +26 -0
- moriarty/assets/modules/nsfw/adultwork.yaml +27 -0
- moriarty/assets/modules/nsfw/bongacams.yaml +28 -0
- moriarty/assets/modules/nsfw/cam4.yaml +28 -0
- moriarty/assets/modules/nsfw/chaturbate.yaml +28 -0
- moriarty/assets/modules/nsfw/clips4sale.yaml +27 -0
- moriarty/assets/modules/nsfw/extralunchmoney.yaml +27 -0
- moriarty/assets/modules/nsfw/fansly.yaml +28 -0
- moriarty/assets/modules/nsfw/fetlife.yaml +28 -0
- moriarty/assets/modules/nsfw/iwantclips.yaml +27 -0
- moriarty/assets/modules/nsfw/justforfans.yaml +28 -0
- moriarty/assets/modules/nsfw/loyalfans.yaml +28 -0
- moriarty/assets/modules/nsfw/manyvids.yaml +27 -0
- moriarty/assets/modules/nsfw/myfreecams.yaml +28 -0
- moriarty/assets/modules/nsfw/niteflirt.yaml +26 -0
- moriarty/assets/modules/nsfw/pornhub.yaml +32 -0
- moriarty/assets/modules/nsfw/redtube.yaml +27 -0
- moriarty/assets/modules/nsfw/stripchat.yaml +28 -0
- moriarty/assets/modules/nsfw/xhamster.yaml +27 -0
- moriarty/assets/modules/nsfw/xvideos.yaml +27 -0
- moriarty/assets/modules/nsfw/youporn.yaml +27 -0
- moriarty/assets/modules/photography/eyeem.yaml +25 -0
- moriarty/assets/modules/photography/fotki.yaml +25 -0
- moriarty/assets/modules/photography/photobucket.yaml +26 -0
- moriarty/assets/modules/photography/smugmug.yaml +25 -0
- moriarty/assets/modules/photography/vsco.yaml +27 -0
- moriarty/assets/modules/pinterest.yaml +40 -0
- moriarty/assets/modules/podcasts/anchor.yaml +26 -0
- moriarty/assets/modules/podcasts/castbox.yaml +26 -0
- moriarty/assets/modules/podcasts/podbean.yaml +26 -0
- moriarty/assets/modules/professional/about.yaml +31 -0
- moriarty/assets/modules/professional/academia.yaml +27 -0
- moriarty/assets/modules/professional/angellist.yaml +27 -0
- moriarty/assets/modules/professional/calendly.yaml +26 -0
- moriarty/assets/modules/professional/issuu.yaml +27 -0
- moriarty/assets/modules/professional/mendeley.yaml +27 -0
- moriarty/assets/modules/professional/notion.yaml +27 -0
- moriarty/assets/modules/professional/orcid.yaml +27 -0
- moriarty/assets/modules/professional/producthunt.yaml +31 -0
- moriarty/assets/modules/professional/researchgate.yaml +32 -0
- moriarty/assets/modules/professional/scribd.yaml +27 -0
- moriarty/assets/modules/professional/slideshare.yaml +31 -0
- moriarty/assets/modules/professional/trello.yaml +26 -0
- moriarty/assets/modules/professional/typeform.yaml +27 -0
- moriarty/assets/modules/reddit.yaml +46 -0
- moriarty/assets/modules/regional/amino.yaml +27 -0
- moriarty/assets/modules/regional/ask-fm.yaml +32 -0
- moriarty/assets/modules/regional/babycenter.yaml +26 -0
- moriarty/assets/modules/regional/cafemom.yaml +27 -0
- moriarty/assets/modules/regional/care2.yaml +27 -0
- moriarty/assets/modules/regional/diaspora.yaml +26 -0
- moriarty/assets/modules/regional/ello.yaml +27 -0
- moriarty/assets/modules/regional/gaia.yaml +27 -0
- moriarty/assets/modules/regional/habbo.yaml +27 -0
- moriarty/assets/modules/regional/imvu.yaml +27 -0
- moriarty/assets/modules/regional/lemmy.yaml +27 -0
- moriarty/assets/modules/regional/peertube.yaml +26 -0
- moriarty/assets/modules/regional/pixelfed.yaml +27 -0
- moriarty/assets/modules/regional/plurk.yaml +26 -0
- moriarty/assets/modules/regional/recroom.yaml +27 -0
- moriarty/assets/modules/regional/secondlife.yaml +26 -0
- moriarty/assets/modules/regional/vine-archive.yaml +27 -0
- moriarty/assets/modules/regional/vrchat.yaml +27 -0
- moriarty/assets/modules/regional/weheartit.yaml +27 -0
- moriarty/assets/modules/social/anilist.yaml +27 -0
- moriarty/assets/modules/social/beacons.yaml +26 -0
- moriarty/assets/modules/social/blogger.yaml +27 -0
- moriarty/assets/modules/social/crunchyroll.yaml +27 -0
- moriarty/assets/modules/social/discord.yaml +27 -0
- moriarty/assets/modules/social/dreamwidth.yaml +26 -0
- moriarty/assets/modules/social/facebook.yaml +34 -0
- moriarty/assets/modules/social/goodreads.yaml +32 -0
- moriarty/assets/modules/social/imdb.yaml +27 -0
- moriarty/assets/modules/social/kitsu.yaml +27 -0
- moriarty/assets/modules/social/letterboxd.yaml +32 -0
- moriarty/assets/modules/social/linktree.yaml +26 -0
- moriarty/assets/modules/social/livejournal.yaml +27 -0
- moriarty/assets/modules/social/mastodon.yaml +30 -0
- moriarty/assets/modules/social/minds.yaml +25 -0
- moriarty/assets/modules/social/myanimelist.yaml +32 -0
- moriarty/assets/modules/social/ravelry.yaml +27 -0
- moriarty/assets/modules/social/snapchat.yaml +25 -0
- moriarty/assets/modules/social/telegram.yaml +35 -0
- moriarty/assets/modules/social/tiktok.yaml +35 -0
- moriarty/assets/modules/social/trakt.yaml +28 -0
- moriarty/assets/modules/social/wattpad.yaml +32 -0
- moriarty/assets/modules/social/wordpress-com.yaml +26 -0
- moriarty/assets/modules/sports/espn.yaml +26 -0
- moriarty/assets/modules/sports/untappd.yaml +32 -0
- moriarty/assets/modules/stackoverflow.yaml +47 -0
- moriarty/assets/modules/steam.yaml +47 -0
- moriarty/assets/modules/streaming/caffeine.yaml +25 -0
- moriarty/assets/modules/streaming/dlive.yaml +27 -0
- moriarty/assets/modules/streaming/trovo.yaml +25 -0
- moriarty/assets/modules/travel/airbnb.yaml +26 -0
- moriarty/assets/modules/travel/booking.yaml +26 -0
- moriarty/assets/modules/travel/couchsurfing.yaml +27 -0
- moriarty/assets/modules/travel/tripadvisor.yaml +32 -0
- moriarty/assets/modules/tumblr.yaml +40 -0
- moriarty/assets/modules/twitch.yaml +48 -0
- moriarty/assets/modules/twitter.yaml +39 -0
- moriarty/assets/modules/youtube.yaml +42 -0
- moriarty/assets/templates/cves/CVE-2017-5638.yaml +27 -0
- moriarty/assets/templates/cves/CVE-2018-7600.yaml +30 -0
- moriarty/assets/templates/cves/CVE-2019-11510.yaml +27 -0
- moriarty/assets/templates/cves/CVE-2019-19781.yaml +28 -0
- moriarty/assets/templates/cves/CVE-2020-14882.yaml +28 -0
- moriarty/assets/templates/cves/CVE-2020-14883.yaml +29 -0
- moriarty/assets/templates/cves/CVE-2020-3452.yaml +28 -0
- moriarty/assets/templates/cves/CVE-2020-5902.yaml +28 -0
- moriarty/assets/templates/cves/CVE-2021-21972.yaml +31 -0
- moriarty/assets/templates/cves/CVE-2021-21985.yaml +28 -0
- moriarty/assets/templates/cves/CVE-2021-26084.yaml +30 -0
- moriarty/assets/templates/cves/CVE-2021-41773.yaml +25 -0
- moriarty/assets/templates/cves/CVE-2021-42013.yaml +28 -0
- moriarty/assets/templates/cves/CVE-2021-44228.yaml +27 -0
- moriarty/assets/templates/cves/CVE-2022-0185.yaml +21 -0
- moriarty/assets/templates/cves/CVE-2022-1388.yaml +36 -0
- moriarty/assets/templates/cves/CVE-2022-22954.yaml +28 -0
- moriarty/assets/templates/cves/CVE-2022-22965.yaml +31 -0
- moriarty/assets/templates/cves/CVE-2022-26134.yaml +27 -0
- moriarty/assets/templates/cves/CVE-2023-22515.yaml +27 -0
- moriarty/assets/templates/cves/CVE-2023-22527.yaml +29 -0
- moriarty/assets/templates/cves/CVE-2023-23752.yaml +33 -0
- moriarty/assets/templates/cves/CVE-2023-27350.yaml +27 -0
- moriarty/assets/templates/cves/CVE-2023-2868.yaml +27 -0
- moriarty/assets/templates/cves/CVE-2023-34362.yaml +27 -0
- moriarty/assets/templates/cves/CVE-2023-3519.yaml +28 -0
- moriarty/assets/templates/cves/CVE-2023-4966.yaml +27 -0
- moriarty/assets/templates/default-logins/admin-weak.yaml +40 -0
- moriarty/assets/templates/default-logins/wordpress-default.yaml +38 -0
- moriarty/assets/templates/exposures/aws-credentials.yaml +35 -0
- moriarty/assets/templates/exposures/backup-files.yaml +36 -0
- moriarty/assets/templates/exposures/database-files.yaml +34 -0
- moriarty/assets/templates/exposures/docker-exposed.yaml +31 -0
- moriarty/assets/templates/exposures/env-exposed.yaml +41 -0
- moriarty/assets/templates/exposures/git-exposed.yaml +41 -0
- moriarty/assets/templates/exposures/phpinfo.yaml +36 -0
- moriarty/assets/templates/exposures/svn-exposed.yaml +28 -0
- moriarty/assets/templates/fuzzing/api-endpoints.yaml +39 -0
- moriarty/assets/templates/fuzzing/common-files.yaml +37 -0
- moriarty/assets/templates/fuzzing/open-redirect-fuzz.yaml +35 -0
- moriarty/assets/templates/fuzzing/xss-search-fuzz.yaml +29 -0
- moriarty/assets/templates/git-config.yaml +18 -0
- moriarty/assets/templates/misconfigurations/cors-misconfiguration.yaml +30 -0
- moriarty/assets/templates/misconfigurations/debug-enabled.yaml +29 -0
- moriarty/assets/templates/misconfigurations/directory-listing.yaml +33 -0
- moriarty/assets/templates/misconfigurations/jwt-none-algo.yaml +30 -0
- moriarty/assets/templates/misconfigurations/ssl-tls-weak.yaml +23 -0
- moriarty/assets/templates/vulnerabilities/lfi-basic.yaml +31 -0
- moriarty/assets/templates/vulnerabilities/open-redirect.yaml +31 -0
- moriarty/assets/templates/vulnerabilities/rce-basic.yaml +34 -0
- moriarty/assets/templates/vulnerabilities/sqli-error.yaml +39 -0
- moriarty/assets/templates/vulnerabilities/ssrf-basic.yaml +31 -0
- moriarty/assets/templates/vulnerabilities/xss-reflected.yaml +38 -0
- moriarty/assets/templates/vulnerabilities/xxe-basic.yaml +30 -0
- moriarty/assets/wordlists/subdomains-1000.txt +1063 -0
- moriarty/cli/__init__.py +3 -0
- moriarty/cli/app.py +120 -0
- moriarty/cli/async_utils.py +19 -0
- moriarty/cli/dns.py +83 -0
- moriarty/cli/domain_cmd.py +572 -0
- moriarty/cli/email.py +383 -0
- moriarty/cli/email_investigate.py +224 -0
- moriarty/cli/intelligence.py +329 -0
- moriarty/cli/output.py +62 -0
- moriarty/cli/rdap.py +94 -0
- moriarty/cli/state.py +38 -0
- moriarty/cli/tls.py +91 -0
- moriarty/cli/user.py +227 -0
- moriarty/core/cache_backend.py +223 -0
- moriarty/core/config_manager.py +303 -0
- moriarty/correlator/__init__.py +0 -0
- moriarty/data/__init__.py +81 -0
- moriarty/data/ioc/__init__.py +142 -0
- moriarty/data/ioc/matcher.py +254 -0
- moriarty/data/ioc/types.py +267 -0
- moriarty/data/local_intelligence.py +507 -0
- moriarty/data/signature_loaders/__init__.py +103 -0
- moriarty/data/signature_loaders/base.py +54 -0
- moriarty/data/signature_loaders/ioc_feed.py +356 -0
- moriarty/data/signature_loaders/wappalyzer.py +112 -0
- moriarty/dsl/__init__.py +0 -0
- moriarty/dsl/loader.py +99 -0
- moriarty/dsl/schema.py +47 -0
- moriarty/export/__init__.py +0 -0
- moriarty/intelligence/__init__.py +27 -0
- moriarty/intelligence/__main__.py +150 -0
- moriarty/intelligence/config.py +395 -0
- moriarty/intelligence/ioc.py +267 -0
- moriarty/intelligence/signatures.py +550 -0
- moriarty/intelligence/storage.py +501 -0
- moriarty/interop/__init__.py +0 -0
- moriarty/logging/__init__.py +0 -0
- moriarty/logging/config.py +47 -0
- moriarty/models/__init__.py +16 -0
- moriarty/models/assertion.py +24 -0
- moriarty/models/entity.py +22 -0
- moriarty/models/evidence.py +37 -0
- moriarty/models/relation.py +24 -0
- moriarty/models/types.py +28 -0
- moriarty/modules/__init__.py +0 -0
- moriarty/modules/avatar_hash.py +184 -0
- moriarty/modules/directory_fuzzer.py +322 -0
- moriarty/modules/dns_scan.py +40 -0
- moriarty/modules/domain_scanner.py +620 -0
- moriarty/modules/email_check.py +98 -0
- moriarty/modules/email_investigate.py +267 -0
- moriarty/modules/email_security.py +274 -0
- moriarty/modules/googlemaps_lookup.py +106 -0
- moriarty/modules/headless_executor.py +201 -0
- moriarty/modules/orchestrator.py +60 -0
- moriarty/modules/passive_recon.py +444 -0
- moriarty/modules/phone_extractor.py +151 -0
- moriarty/modules/pipeline_orchestrator.py +726 -0
- moriarty/modules/port_scanner.py +129 -0
- moriarty/modules/rdap.py +61 -0
- moriarty/modules/rdap_extended.py +188 -0
- moriarty/modules/stealth_mode.py +610 -0
- moriarty/modules/subdomain_discovery.py +595 -0
- moriarty/modules/technology_profiler.py +361 -0
- moriarty/modules/template_executor.py +239 -0
- moriarty/modules/template_scanner.py +1048 -0
- moriarty/modules/tls_scan.py +46 -0
- moriarty/modules/tls_validator.py +188 -0
- moriarty/modules/vuln_scanner.py +483 -0
- moriarty/modules/waf_detector.py +585 -0
- moriarty/modules/wayback_discovery.py +234 -0
- moriarty/modules/web_crawler.py +163 -0
- moriarty/net/__init__.py +0 -0
- moriarty/net/dns_cache.py +175 -0
- moriarty/net/dns_client.py +188 -0
- moriarty/net/rdap_client.py +52 -0
- moriarty/net/smtp_client.py +114 -0
- moriarty/net/tls_client.py +111 -0
- moriarty/parsers/__init__.py +0 -0
- moriarty/parsers/html_parser.py +136 -0
- moriarty/tests/__init__.py +0 -0
- moriarty/tests/test_email_service.py +17 -0
- moriarty/tests/test_models.py +46 -0
- moriarty/tests/test_orchestrator.py +30 -0
- moriarty/tests/test_tls_client.py +18 -0
- moriarty_project-0.1.6.dist-info/METADATA +388 -0
- moriarty_project-0.1.6.dist-info/RECORD +418 -0
- moriarty_project-0.1.6.dist-info/WHEEL +4 -0
- moriarty_project-0.1.6.dist-info/entry_points.txt +2 -0
@@ -0,0 +1,572 @@
|
|
1
|
+
"""Comandos de scanning de domínios/IPs."""
|
2
|
+
import json
|
3
|
+
from typing import Optional
|
4
|
+
|
5
|
+
import typer
|
6
|
+
|
7
|
+
from moriarty.modules.port_scanner import PROFILES
|
8
|
+
from moriarty.modules.passive_recon import PassiveRecon
|
9
|
+
from rich.console import Console
|
10
|
+
|
11
|
+
app = typer.Typer(name="domain", help="🌐 Domain/IP reconnaissance and scanning.")
|
12
|
+
console = Console()
|
13
|
+
|
14
|
+
|
15
|
+
@app.command("scan")
|
16
|
+
def scan_full(
|
17
|
+
target: str = typer.Argument(..., help="Domain ou IP alvo"),
|
18
|
+
modules: str = typer.Option(
|
19
|
+
"all",
|
20
|
+
"--modules",
|
21
|
+
"-m",
|
22
|
+
help="Módulos: all,dns,subdiscover,wayback,ports,ssl,crawl,fuzzer,template-scan,vuln-scan,waf-detect",
|
23
|
+
),
|
24
|
+
stealth: int = typer.Option(0, "--stealth", "-s", help="Stealth level (0-4)"),
|
25
|
+
threads: int = typer.Option(10, "--threads", "-t", help="Threads concorrentes"),
|
26
|
+
timeout: int = typer.Option(30, "--timeout", help="Timeout em segundos"),
|
27
|
+
output: str = typer.Option(None, "--output", "-o", help="Arquivo de saída"),
|
28
|
+
):
|
29
|
+
"""
|
30
|
+
🔍 Scan completo de domínio/IP com 14 módulos.
|
31
|
+
|
32
|
+
Exemplos:
|
33
|
+
moriarty domain scan example.com
|
34
|
+
moriarty domain scan 8.8.8.8 --stealth 3
|
35
|
+
moriarty domain scan target.com --modules dns,ports,ssl
|
36
|
+
"""
|
37
|
+
from moriarty.modules.domain_scanner import DomainScanner
|
38
|
+
import asyncio
|
39
|
+
import logging
|
40
|
+
|
41
|
+
# Suprime logs verbosos globalmente
|
42
|
+
logging.getLogger("httpx").setLevel(logging.ERROR)
|
43
|
+
logging.getLogger("httpcore").setLevel(logging.ERROR)
|
44
|
+
logging.getLogger("moriarty").setLevel(logging.ERROR)
|
45
|
+
|
46
|
+
scanner = DomainScanner(
|
47
|
+
target=target,
|
48
|
+
modules=modules.split(",") if modules != "all" else None,
|
49
|
+
stealth_level=stealth,
|
50
|
+
threads=threads,
|
51
|
+
timeout=timeout,
|
52
|
+
)
|
53
|
+
|
54
|
+
asyncio.run(scanner.run())
|
55
|
+
|
56
|
+
if output:
|
57
|
+
scanner.export(output)
|
58
|
+
console.print(f"[green]✅[/green] Results saved to: [cyan]{output}[/cyan]\n")
|
59
|
+
|
60
|
+
|
61
|
+
@app.command("subdiscover")
|
62
|
+
def subdomain_discovery(
|
63
|
+
domain: str = typer.Argument(..., help="Domínio alvo"),
|
64
|
+
sources: str = typer.Option("all", "--sources", "-s", help="Fontes: all,crtsh,virustotal,..."),
|
65
|
+
validate: bool = typer.Option(True, "--validate/--no-validate", help="Validar subdomínios encontrados"),
|
66
|
+
recursive: bool = typer.Option(False, "--recursive", "-r", help="Busca recursiva"),
|
67
|
+
wordlist: str = typer.Option(None, "--wordlist", "-w", help="Wordlist personalizada"),
|
68
|
+
output: str = typer.Option(None, "--output", "-o", help="Arquivo de saída"),
|
69
|
+
):
|
70
|
+
"""
|
71
|
+
🔍 Descoberta de subdomínios usando 20+ fontes.
|
72
|
+
|
73
|
+
Fontes suportadas:
|
74
|
+
- crt.sh (Certificate Transparency)
|
75
|
+
- VirusTotal
|
76
|
+
- SecurityTrails
|
77
|
+
- Shodan
|
78
|
+
- DNSDumpster
|
79
|
+
- AlienVault OTX
|
80
|
+
- ThreatCrowd
|
81
|
+
- Wayback Machine
|
82
|
+
- CommonCrawl
|
83
|
+
- Google Dorking
|
84
|
+
- Bing
|
85
|
+
- Yahoo
|
86
|
+
- Ask
|
87
|
+
- DNS Bruteforce
|
88
|
+
- Zone Transfer
|
89
|
+
- Reverse DNS
|
90
|
+
- DNSSEC
|
91
|
+
- NSEC Walking
|
92
|
+
- Subdomain Permutations
|
93
|
+
- GitHub Code Search
|
94
|
+
"""
|
95
|
+
from moriarty.modules.subdomain_discovery import SubdomainDiscovery
|
96
|
+
import asyncio
|
97
|
+
|
98
|
+
console.print(f"[bold cyan]🔍 Descobrindo subdomínios de:[/bold cyan] {domain}\n")
|
99
|
+
|
100
|
+
discovery = SubdomainDiscovery(
|
101
|
+
domain=domain,
|
102
|
+
sources=sources.split(",") if sources != "all" else None,
|
103
|
+
validate=validate,
|
104
|
+
recursive=recursive,
|
105
|
+
wordlist=wordlist,
|
106
|
+
)
|
107
|
+
|
108
|
+
results = asyncio.run(discovery.discover())
|
109
|
+
|
110
|
+
console.print(f"\n[green]✅ {len(results)} subdomínios encontrados[/green]")
|
111
|
+
|
112
|
+
for subdomain in sorted(results):
|
113
|
+
console.print(f" • {subdomain}")
|
114
|
+
|
115
|
+
if output:
|
116
|
+
discovery.export(results, output)
|
117
|
+
|
118
|
+
|
119
|
+
@app.command("wayback")
|
120
|
+
def wayback_urls(
|
121
|
+
domain: str = typer.Argument(..., help="Domínio alvo"),
|
122
|
+
validate: bool = typer.Option(True, "--validate/--no-validate", help="Validar URLs ativas"),
|
123
|
+
filter_ext: str = typer.Option(None, "--filter", "-f", help="Filtrar extensões (ex: php,asp,jsp)"),
|
124
|
+
status_filter: str = typer.Option(None, "--status", help="Filtrar status codes (ex: 200,404,301)"),
|
125
|
+
years: int = typer.Option(5, "--years", "-y", help="Anos para buscar"),
|
126
|
+
output: str = typer.Option(None, "--output", "-o", help="Arquivo de saída"),
|
127
|
+
):
|
128
|
+
"""
|
129
|
+
🕰️ Descobre URLs históricas via Wayback Machine.
|
130
|
+
|
131
|
+
Exemplos:
|
132
|
+
moriarty domain wayback example.com
|
133
|
+
moriarty domain wayback target.com --filter php,asp --years 10
|
134
|
+
"""
|
135
|
+
from moriarty.modules.wayback_discovery import WaybackDiscovery
|
136
|
+
import asyncio
|
137
|
+
|
138
|
+
console.print(f"[bold cyan]🕰️ Buscando URLs históricas de:[/bold cyan] {domain}\n")
|
139
|
+
|
140
|
+
wayback = WaybackDiscovery(
|
141
|
+
domain=domain,
|
142
|
+
validate=validate,
|
143
|
+
filter_extensions=filter_ext.split(",") if filter_ext else None,
|
144
|
+
filter_status_codes=[int(code.strip()) for code in status_filter.split(",") if code.strip()]
|
145
|
+
if status_filter
|
146
|
+
else None,
|
147
|
+
years_back=years,
|
148
|
+
)
|
149
|
+
|
150
|
+
urls = asyncio.run(wayback.discover())
|
151
|
+
|
152
|
+
console.print(f"\n[green]✅ {len(urls)} URLs encontradas[/green]")
|
153
|
+
|
154
|
+
if output:
|
155
|
+
wayback.export(urls, output)
|
156
|
+
|
157
|
+
|
158
|
+
@app.command("template-scan")
|
159
|
+
def template_scan(
|
160
|
+
target: str = typer.Argument(..., help="Alvo (domain ou IP)"),
|
161
|
+
templates: str = typer.Option(None, "--templates", "-t", help="Path para templates ou tag"),
|
162
|
+
severity: str = typer.Option("all", "--severity", "-s", help="Severidade: all,critical,high,medium,low"),
|
163
|
+
threads: int = typer.Option(20, "--threads", help="Threads concorrentes"),
|
164
|
+
output: str = typer.Option(None, "--output", "-o", help="Arquivo de saída"),
|
165
|
+
):
|
166
|
+
"""
|
167
|
+
📝 Scan baseado em templates (estilo Nuclei).
|
168
|
+
|
169
|
+
Exemplos:
|
170
|
+
moriarty domain template-scan example.com
|
171
|
+
moriarty domain template-scan target.com --templates cves/
|
172
|
+
moriarty domain template-scan target.com --severity critical,high
|
173
|
+
"""
|
174
|
+
import asyncio
|
175
|
+
|
176
|
+
from moriarty.modules.template_scanner import TemplateScanner
|
177
|
+
|
178
|
+
console.print(f"[bold cyan]📝 Template scan em:[/bold cyan] {target}\n")
|
179
|
+
|
180
|
+
scanner = TemplateScanner(
|
181
|
+
target=target,
|
182
|
+
templates_path=templates,
|
183
|
+
severity_filter=severity.split(",") if severity != "all" else None,
|
184
|
+
threads=threads,
|
185
|
+
)
|
186
|
+
|
187
|
+
results = asyncio.run(scanner.scan())
|
188
|
+
|
189
|
+
console.print(f"\n[bold]Resultados:[/bold]")
|
190
|
+
for severity_level in ["critical", "high", "medium", "low", "info"]:
|
191
|
+
findings = [r for r in results if r.severity == severity_level]
|
192
|
+
if findings:
|
193
|
+
color = {"critical": "red", "high": "yellow", "medium": "blue", "low": "green", "info": "dim"}[severity_level]
|
194
|
+
console.print(f"[{color}]• {severity_level.upper()}: {len(findings)} findings[/{color}]")
|
195
|
+
|
196
|
+
if output:
|
197
|
+
scanner.export(results, output)
|
198
|
+
|
199
|
+
|
200
|
+
@app.command("pipeline")
|
201
|
+
def run_pipeline(
|
202
|
+
pipeline_file: str = typer.Argument(..., help="Arquivo YAML do pipeline"),
|
203
|
+
target: str = typer.Option(None, "--target", "-t", help="Alvo (sobrescreve YAML)"),
|
204
|
+
vars_file: str = typer.Option(None, "--vars", "-v", help="Arquivo de variáveis"),
|
205
|
+
dry_run: bool = typer.Option(False, "--dry-run", help="Simular sem executar"),
|
206
|
+
):
|
207
|
+
"""
|
208
|
+
🔄 Executa pipeline de scan via YAML declarativo.
|
209
|
+
|
210
|
+
Exemplo de pipeline.yaml:
|
211
|
+
name: "Full Recon"
|
212
|
+
target: "example.com"
|
213
|
+
stages:
|
214
|
+
- name: "DNS Discovery"
|
215
|
+
module: "dns"
|
216
|
+
- name: "Subdomain Enum"
|
217
|
+
module: "subdiscover"
|
218
|
+
- name: "Port Scan"
|
219
|
+
module: "ports"
|
220
|
+
"""
|
221
|
+
from moriarty.modules.pipeline_orchestrator import PipelineOrchestrator
|
222
|
+
import asyncio
|
223
|
+
|
224
|
+
console.print(f"[bold cyan]🔄 Executando pipeline:[/bold cyan] {pipeline_file}\n")
|
225
|
+
|
226
|
+
orchestrator = PipelineOrchestrator(
|
227
|
+
pipeline_file=pipeline_file,
|
228
|
+
target_override=target,
|
229
|
+
vars_file=vars_file,
|
230
|
+
dry_run=dry_run,
|
231
|
+
)
|
232
|
+
|
233
|
+
asyncio.run(orchestrator.run())
|
234
|
+
|
235
|
+
|
236
|
+
@app.command("stealth")
|
237
|
+
def stealth_command(
|
238
|
+
action: str = typer.Argument(..., help="Ação: scan, config, proxy, test"),
|
239
|
+
target: str = typer.Option(None, "--target", "-t", help="Alvo para scan/test"),
|
240
|
+
level: int = typer.Option(2, "--level", "-l", help="Nível stealth (0-4)"),
|
241
|
+
):
|
242
|
+
"""
|
243
|
+
🥷 Stealth Mode - Sistema completo de evasão.
|
244
|
+
|
245
|
+
Níveis:
|
246
|
+
0 - Disabled: Sem stealth
|
247
|
+
1 - Low: Randomização básica
|
248
|
+
2 - Medium: Proxies + timing
|
249
|
+
3 - High: Fragmentação + adaptativo
|
250
|
+
4 - Paranoid: Todas técnicas + decoys
|
251
|
+
|
252
|
+
Exemplos:
|
253
|
+
moriarty domain stealth scan example.com --level 3
|
254
|
+
moriarty domain stealth config
|
255
|
+
moriarty domain stealth test --target example.com
|
256
|
+
"""
|
257
|
+
from moriarty.modules.stealth_mode import StealthMode
|
258
|
+
import asyncio
|
259
|
+
|
260
|
+
stealth = StealthMode(level=level)
|
261
|
+
|
262
|
+
if action == "config":
|
263
|
+
stealth.show_config()
|
264
|
+
elif action == "scan":
|
265
|
+
if not target:
|
266
|
+
console.print("[red]❌ --target é obrigatório para scan[/red]")
|
267
|
+
raise typer.Exit(1)
|
268
|
+
asyncio.run(stealth.scan(target))
|
269
|
+
elif action == "proxy":
|
270
|
+
stealth.manage_proxies()
|
271
|
+
elif action == "test":
|
272
|
+
if not target:
|
273
|
+
console.print("[red]❌ --target é obrigatório para test[/red]")
|
274
|
+
raise typer.Exit(1)
|
275
|
+
asyncio.run(stealth.test_capabilities(target))
|
276
|
+
else:
|
277
|
+
console.print(f"[red]❌ Ação inválida: {action}[/red]")
|
278
|
+
|
279
|
+
|
280
|
+
@app.command("ports")
|
281
|
+
def port_scan(
|
282
|
+
target: str = typer.Argument(..., help="IP ou domínio"),
|
283
|
+
ports: str = typer.Option("common", "--ports", "-p", help="Portas: common, all, 1-1000, 80,443"),
|
284
|
+
scan_type: str = typer.Option("syn", "--type", "-t", help="Tipo: syn, tcp, udp"),
|
285
|
+
stealth: int = typer.Option(0, "--stealth", "-s", help="Stealth level (0-4)"),
|
286
|
+
output: str = typer.Option(None, "--output", "-o", help="Arquivo de saída"),
|
287
|
+
):
|
288
|
+
"""
|
289
|
+
🔌 Scan avançado de portas.
|
290
|
+
|
291
|
+
Exemplos:
|
292
|
+
moriarty domain ports 8.8.8.8
|
293
|
+
moriarty domain ports target.com --ports 1-10000
|
294
|
+
moriarty domain ports target.com --type syn --stealth 3
|
295
|
+
"""
|
296
|
+
from moriarty.modules.port_scanner import PortScanner
|
297
|
+
import asyncio
|
298
|
+
|
299
|
+
console.print(f"[bold cyan]🔌 Port scan em:[/bold cyan] {target}\n")
|
300
|
+
|
301
|
+
scanner = PortScanner(
|
302
|
+
target=target,
|
303
|
+
ports=ports,
|
304
|
+
scan_type=scan_type,
|
305
|
+
stealth_level=stealth,
|
306
|
+
)
|
307
|
+
|
308
|
+
results = asyncio.run(scanner.scan())
|
309
|
+
|
310
|
+
console.print(f"\n[green]✅ {len(results)} portas abertas encontradas[/green]")
|
311
|
+
|
312
|
+
if output:
|
313
|
+
scanner.export(results, output)
|
314
|
+
|
315
|
+
|
316
|
+
@app.command("waf-detect")
|
317
|
+
def waf_detection(
|
318
|
+
target: str = typer.Argument(..., help="URL alvo"),
|
319
|
+
bypass: bool = typer.Option(False, "--bypass", "-b", help="Tentar bypass automático"),
|
320
|
+
):
|
321
|
+
"""
|
322
|
+
🛡️ Detecta WAF/IPS e tenta bypass automático.
|
323
|
+
|
324
|
+
Detecta:
|
325
|
+
- Cloudflare
|
326
|
+
- AWS WAF
|
327
|
+
- Akamai
|
328
|
+
- Imperva
|
329
|
+
- F5 BIG-IP
|
330
|
+
- ModSecurity
|
331
|
+
- Sucuri
|
332
|
+
- Barracuda
|
333
|
+
- Fortinet
|
334
|
+
"""
|
335
|
+
from moriarty.modules.waf_detector import WAFDetector
|
336
|
+
import asyncio
|
337
|
+
|
338
|
+
console.print(f"[bold cyan]🛡️ Detectando WAF em:[/bold cyan] {target}\n")
|
339
|
+
|
340
|
+
detector = WAFDetector(target=target)
|
341
|
+
waf_info = asyncio.run(detector.detect())
|
342
|
+
|
343
|
+
if waf_info:
|
344
|
+
console.print(f"[yellow]⚠️ WAF detectado:[/yellow] {waf_info['name']}")
|
345
|
+
console.print(f"[dim]Confidence: {waf_info['confidence']}%[/dim]")
|
346
|
+
|
347
|
+
if bypass:
|
348
|
+
console.print("\n[cyan]🔓 Tentando bypass...[/cyan]")
|
349
|
+
bypass_methods = asyncio.run(detector.attempt_bypass())
|
350
|
+
|
351
|
+
for method in bypass_methods:
|
352
|
+
if method['success']:
|
353
|
+
console.print(f"[green]✅ Bypass bem-sucedido:[/green] {method['technique']}")
|
354
|
+
else:
|
355
|
+
console.print("[green]✅ Nenhum WAF detectado[/green]")
|
356
|
+
|
357
|
+
|
358
|
+
__all__ = ["app"]
|
359
|
+
@app.command("recon")
|
360
|
+
def passive_recon(
|
361
|
+
domain: str = typer.Argument(..., help="Domínio alvo"),
|
362
|
+
output: Optional[str] = typer.Option(None, "--output", "-o", help="Arquivo JSON de saída"),
|
363
|
+
status_only: bool = typer.Option(False, "--status-only", help="Mostrar apenas resumo"),
|
364
|
+
):
|
365
|
+
"""
|
366
|
+
🌐 Coleta passiva de inteligência sobre domínios.
|
367
|
+
|
368
|
+
Exemplos:
|
369
|
+
moriarty domain recon example.com
|
370
|
+
moriarty domain recon target.com --output resultado.json
|
371
|
+
"""
|
372
|
+
import asyncio
|
373
|
+
import json
|
374
|
+
import logging
|
375
|
+
from datetime import datetime
|
376
|
+
from rich.console import Console
|
377
|
+
from rich.table import Table
|
378
|
+
from rich.panel import Panel
|
379
|
+
from rich import box
|
380
|
+
|
381
|
+
# Configuração de logs
|
382
|
+
logging.getLogger("httpx").setLevel(logging.ERROR)
|
383
|
+
logging.getLogger("httpcore").setLevel(logging.ERROR)
|
384
|
+
logging.getLogger("moriarty").setLevel(logging.ERROR)
|
385
|
+
|
386
|
+
console = Console()
|
387
|
+
|
388
|
+
# Cabeçalho
|
389
|
+
console.print(f"\n[bold cyan]🌐 Moriarty Passive Recon[/bold cyan]")
|
390
|
+
console.print(f"[dim]Alvo:[/dim] {domain}")
|
391
|
+
console.print(f"[dim]Data:[/dim] {datetime.now().strftime('%Y-%m-%d %H:%M:%S')}\n")
|
392
|
+
|
393
|
+
async def _run():
|
394
|
+
with console.status(f"[bold green]Coletando informações sobre [cyan]{domain}[/cyan]..."):
|
395
|
+
recon = PassiveRecon(domain)
|
396
|
+
try:
|
397
|
+
return await recon.collect()
|
398
|
+
finally:
|
399
|
+
await recon.close()
|
400
|
+
|
401
|
+
try:
|
402
|
+
result = asyncio.run(_run())
|
403
|
+
payload = result.to_dict()
|
404
|
+
|
405
|
+
if status_only:
|
406
|
+
sub_count = sum(len(v) for v in payload["subdomains"].values())
|
407
|
+
console.print(f"[bold]🔍 Resumo do Reconhecimento[/bold]")
|
408
|
+
console.print(f" • [cyan]Subdomínios:[/cyan] {sub_count} encontrados")
|
409
|
+
console.print(f" • [cyan]Fontes:[/cyan] {', '.join(payload['subdomains'].keys()) or 'nenhuma'}")
|
410
|
+
console.print(f" • [cyan]Credenciais vazadas:[/cyan] {len(payload['leaks'])}")
|
411
|
+
return
|
412
|
+
|
413
|
+
# Seção de Subdomínios
|
414
|
+
if payload.get("subdomains"):
|
415
|
+
table = Table(title="[bold]🌐 Subdomínios Encontrados[/bold]", box=box.ROUNDED)
|
416
|
+
table.add_column("Subdomínio", style="cyan")
|
417
|
+
table.add_column("Fonte", style="green")
|
418
|
+
|
419
|
+
for source, subdomains in payload["subdomains"].items():
|
420
|
+
for sub in subdomains:
|
421
|
+
table.add_row(sub, source)
|
422
|
+
|
423
|
+
console.print(Panel.fit(table, border_style="blue"))
|
424
|
+
|
425
|
+
# Seção de Tecnologias
|
426
|
+
if payload.get("technologies", {}).get("detections"):
|
427
|
+
tech_table = Table(title="[bold]🛠️ Tecnologias Detectadas[/bold]", box=box.ROUNDED)
|
428
|
+
tech_table.add_column("Tecnologia", style="cyan")
|
429
|
+
tech_table.add_column("Confiança", style="green")
|
430
|
+
tech_table.add_column("Categoria", style="magenta")
|
431
|
+
|
432
|
+
for tech in payload["technologies"]["detections"]:
|
433
|
+
tech_table.add_row(
|
434
|
+
tech["name"],
|
435
|
+
f"{tech['confidence']}%",
|
436
|
+
", ".join(tech.get("categories", []))
|
437
|
+
)
|
438
|
+
|
439
|
+
console.print(Panel.fit(tech_table, border_style="blue"))
|
440
|
+
|
441
|
+
# Seção de Segurança
|
442
|
+
security_table = Table(title="[bold]🔒 Análise de Segurança[/bold]", box=box.ROUNDED)
|
443
|
+
security_table.add_column("Item", style="cyan")
|
444
|
+
security_table.add_column("Status", style="green")
|
445
|
+
|
446
|
+
# Verifica HSTS
|
447
|
+
headers = payload.get("technologies", {}).get("headers", {})
|
448
|
+
hsts = "Sim" if "strict-transport-security" in str(headers).lower() else "Não"
|
449
|
+
security_table.add_row("HSTS Habilitado", hsts)
|
450
|
+
|
451
|
+
# Verifica XSS Protection
|
452
|
+
xss_protection = "Sim" if "x-xss-protection" in str(headers).lower() else "Não"
|
453
|
+
security_table.add_row("Proteção XSS", xss_protection)
|
454
|
+
|
455
|
+
# Verifica Content Security Policy
|
456
|
+
csp = "Sim" if "content-security-policy" in str(headers).lower() else "Não"
|
457
|
+
security_table.add_row("Content Security Policy", csp)
|
458
|
+
|
459
|
+
console.print(Panel.fit(security_table, border_style="blue"))
|
460
|
+
|
461
|
+
# Seção de Reputação
|
462
|
+
if payload.get("reputation"):
|
463
|
+
rep_table = Table(title="[bold]📊 Reputação do Domínio[/bold]", box=box.ROUNDED)
|
464
|
+
rep_table.add_column("Fonte", style="cyan")
|
465
|
+
rep_table.add_column("Status", style="green")
|
466
|
+
|
467
|
+
for source, data in payload["reputation"].items():
|
468
|
+
if isinstance(data, dict) and data.get("pulses") is not None:
|
469
|
+
rep_table.add_row(source, f"{len(data['pulses'])} ameaças conhecidas")
|
470
|
+
elif source == "alienvault" and data.get("pulses") is not None:
|
471
|
+
rep_table.add_row("AlienVault OTX", f"{len(data['pulses'])} ameaças conhecidas")
|
472
|
+
|
473
|
+
console.print(Panel.fit(rep_table, border_style="blue"))
|
474
|
+
|
475
|
+
# Seção de Informações WHOIS
|
476
|
+
if payload.get("whois"):
|
477
|
+
whois_info = "\n".join(line for line in payload["whois"].split("\n")
|
478
|
+
if not line.startswith("%") and line.strip())
|
479
|
+
console.print(Panel.fit(
|
480
|
+
f"[bold]📝 Informações de Registro (WHOIS)[/bold]\n\n[dim]{whois_info}",
|
481
|
+
border_style="blue"
|
482
|
+
))
|
483
|
+
|
484
|
+
if output:
|
485
|
+
with open(output, "w", encoding="utf-8") as handle:
|
486
|
+
json.dump(payload, handle, indent=2, ensure_ascii=False)
|
487
|
+
console.print(f"\n[green]✓[/green] Resultados salvos em: [cyan]{output}[/cyan]")
|
488
|
+
|
489
|
+
except Exception as e:
|
490
|
+
console.print(f"[red]✗ Erro durante o reconhecimento:[/red] {str(e)}")
|
491
|
+
if output:
|
492
|
+
with open(output, "w", encoding="utf-8") as handle:
|
493
|
+
json.dump({"error": str(e)}, handle, indent=2)
|
494
|
+
console.print(f"[yellow]⚠ Log de erro salvo em: {output}[/yellow]")
|
495
|
+
|
496
|
+
|
497
|
+
@app.command("ports")
|
498
|
+
def port_scan(
|
499
|
+
domain: str = typer.Argument(..., help="Alvo para o port scan"),
|
500
|
+
profile: str = typer.Option("quick", "--profile", "-p", help=f"Perfil ({', '.join(PROFILES.keys())})"),
|
501
|
+
concurrency: int = typer.Option(200, "--concurrency", help="Conexões simultâneas"),
|
502
|
+
timeout: float = typer.Option(1.5, "--timeout", help="Timeout por porta"),
|
503
|
+
output: Optional[str] = typer.Option(None, "--output", "-o", help="Arquivo de saída JSON"),
|
504
|
+
):
|
505
|
+
"""Executa port scan assíncrono com banners."""
|
506
|
+
import asyncio
|
507
|
+
import json
|
508
|
+
|
509
|
+
async def _run():
|
510
|
+
scanner = PortScanner(
|
511
|
+
target=domain,
|
512
|
+
profile=profile,
|
513
|
+
concurrency=concurrency,
|
514
|
+
timeout=timeout,
|
515
|
+
)
|
516
|
+
return await scanner.scan()
|
517
|
+
|
518
|
+
results = asyncio.run(_run())
|
519
|
+
if not results:
|
520
|
+
console.print("[yellow]Nenhuma porta aberta detectada[/yellow]")
|
521
|
+
else:
|
522
|
+
table_data = [
|
523
|
+
{"port": r.port, "status": r.status, "banner": r.banner or "-"}
|
524
|
+
for r in results
|
525
|
+
]
|
526
|
+
console.print_json(data=table_data)
|
527
|
+
|
528
|
+
if output:
|
529
|
+
json_payload = [r.__dict__ for r in results]
|
530
|
+
with open(output, "w", encoding="utf-8") as handle:
|
531
|
+
json.dump(json_payload, handle, indent=2, ensure_ascii=False)
|
532
|
+
console.print(f"[green]✓ Resultado salvo em[/green] {output}")
|
533
|
+
|
534
|
+
|
535
|
+
@app.command("crawl")
|
536
|
+
def crawl(
|
537
|
+
domain: str = typer.Argument(..., help="Alvo base (ex: https://example.com)"),
|
538
|
+
max_pages: int = typer.Option(100, "--max-pages", help="Máximo de páginas"),
|
539
|
+
max_depth: int = typer.Option(2, "--max-depth", help="Profundidade máxima"),
|
540
|
+
concurrency: int = typer.Option(10, "--concurrency", help="Workers paralelos"),
|
541
|
+
follow_subdomains: bool = typer.Option(False, "--follow-subdomains", help="Seguir subdomínios"),
|
542
|
+
output: Optional[str] = typer.Option(None, "--output", "-o", help="Arquivo JSON de saída"),
|
543
|
+
):
|
544
|
+
"""Crawler leve para mapear formulários e rotas."""
|
545
|
+
import asyncio
|
546
|
+
import json
|
547
|
+
|
548
|
+
async def _run():
|
549
|
+
crawler = WebCrawler(
|
550
|
+
base_url=domain,
|
551
|
+
max_pages=max_pages,
|
552
|
+
max_depth=max_depth,
|
553
|
+
concurrency=concurrency,
|
554
|
+
follow_subdomains=follow_subdomains,
|
555
|
+
)
|
556
|
+
try:
|
557
|
+
return await crawler.crawl()
|
558
|
+
finally:
|
559
|
+
await crawler.close()
|
560
|
+
|
561
|
+
pages = asyncio.run(_run())
|
562
|
+
summary = {
|
563
|
+
"total_pages": len(pages),
|
564
|
+
"forms": sum(len(page.forms) for page in pages.values()),
|
565
|
+
}
|
566
|
+
console.print_json(data=summary)
|
567
|
+
|
568
|
+
if output:
|
569
|
+
payload = {url: page.__dict__ for url, page in pages.items()}
|
570
|
+
with open(output, "w", encoding="utf-8") as handle:
|
571
|
+
json.dump(payload, handle, indent=2, ensure_ascii=False)
|
572
|
+
console.print(f"[green]✓ Resultado salvo em[/green] {output}")
|