aboutsummaryrefslogtreecommitdiff
path: root/battering/packages/osint.scm
blob: 511c287f1fb384cd65a867a9c1abf7abae49d577 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
(define-module (battering packages osint)
  #:use-module (guix build-system python)
  #:use-module (guix build-system pyproject)
  #:use-module (guix download)
  #:use-module (guix git-download)
  #:use-module (guix packages)
  #:use-module (guix gexp)
  #:use-module (gnu packages pdf)
  #:use-module (gnu packages python-build)
  #:use-module (gnu packages python-xyz)
  #:use-module (gnu packages python-web)
  #:use-module (gnu packages python-crypto)
  #:use-module (gnu packages protobuf)
  #:use-module (gnu packages check)
  #:use-module (gnu packages xml)
  #:use-module ((guix licenses)
                #:prefix license:)
  #:use-module (battering packages python-xyz))

(define-public python-linkedin-api
  (package
    (name "python-linkedin-api")
    (version "2.3.1")
    (source
     (origin
       (method url-fetch)
       (uri (pypi-uri "linkedin_api" version))
       (sha256
        (base32 "1169xkkpl1sw9vqq52pc4l14hjdhp8gvdmjmdj7f8jd080205aq7"))))
    (build-system pyproject-build-system)
    (native-inputs (list python-setuptools
                         python-wheel))
    (propagated-inputs (list python-requests
                             python-beautifulsoup4))
    (arguments '(#:tests? #f ;; TODO: fix tests and poetry
                 #:build-backend "setuptools.build_meta"))
    (home-page "https://github.com/tomquirk/linkedin-api")
    (synopsis "LinkedIn API for Python")
    (description "@code{LinkedIn} API for Python.")
    (license license:expat)))

(define-public python-twikit
  (package
    (name "python-twikit")
    (version "2.2.0")
    (source
     (origin
       (method url-fetch)
       (uri (pypi-uri "twikit" version))
       (sha256
        (base32 "0apmz8iw2pv3cicignd41sgr5zy2bbyj9c76j5hw43h7rhgj5jgs"))))
    (build-system pyproject-build-system)
    (native-inputs (list python-setuptools
                         python-wheel))
    (propagated-inputs (list python-beautifulsoup4 python-filetype
                             python-httpx python-lxml python-pyotp
                             python-requests))
    (arguments
     (list #:phases
           #~(modify-phases %standard-phases
               (add-after 'unpack 'fix-httpx
                 (lambda _
                   ;; TODO -- remove this hacky fix once httpx is
                   ;; version-bumped in Guix.
                   (substitute* "twikit/client/client.py"
                     (("AsyncClient\\(proxy=proxy, ") "AsyncClient(")))))))
    (home-page "https://github.com/d60/twikit")
    (synopsis "Twitter API wrapper for python with **no API key required**.")
    (description
     "Twitter API wrapper for python with **no API key required**.")
    (license license:expat)))

(define-public python-discord-protos
  (package
    (name "python-discord-protos")
    (version "0.0.2")
    (source
     (origin
       (method url-fetch)
       (uri (pypi-uri "discord-protos" version))
       (sha256
        (base32 "15y984m2la79g8rmvmy895m1k9ihfm2lpv08nx0dpvibyc2km593"))))
    (build-system pyproject-build-system)
    (native-inputs (list python-setuptools
                         python-wheel))
    (inputs (list python-protobuf))
    (home-page "https://github.com/dolfies/discord-protos")
    (synopsis "Discord user settings protobufs.")
    (description "Discord user settings protobufs.")
    (license license:expat)))

(define-public python-discord.py-self
  (package
    (name "python-discord.py-self")
    (version "2.0.0")
    (source
     (origin
       (method url-fetch)
       (uri (pypi-uri "discord.py-self" version))
       (sha256
        (base32 "05xyd7d1mzn3xsw6crl2bp8y0k71dk07jfadvk9w4x880vk3nr4g"))))
    (build-system pyproject-build-system)
    (native-inputs (list python-coverage
                         python-pytest
                         python-pytest-asyncio
                         python-pytest-cov
                         python-pytest-mock
                         python-setuptools
                         python-wheel))
    (propagated-inputs (list python-aiohttp
                             python-protobuf
                             python-discord-protos
                             python-typing-extensions
                             python-yarl))
    (arguments
     '(#:tests? #f))
    (home-page "https://github.com/dolfies/discord.py-self")
    (synopsis "A Python wrapper for the Discord user API")
    (description
     "This package provides a Python wrapper for the Discord user API.")
    (license license:expat)))

(define-public python-maigret
  (let ((commit "4195a3ca21ce22d30ccc800a48489377bce21865")
        (revision "1"))
    (package
      (name "python-maigret")
      (version (git-version "0.5.0" revision commit))
      (source
       (origin
         (method git-fetch)
         (uri (git-reference
               (url "https://github.com/soxoj/maigret")
               (commit commit)))
         (file-name (git-file-name name version))
         (sha256
          (base32 "0vsg8ampbp7vdppz117555khwfd1bz3jw9fjyidfjdhzcw659x05"))
         (modules '((guix build utils)))
         (snippet
          '(let ((maigret-dir-python "(os.getenv('XDG_DATA_HOME') or (os.getenv('HOME') + '/.local/share/')) + '/maigret'"))
             (substitute* "maigret/maigret.py"
               ;; Default report directory is in /gnu/store
               (("(report_dir = .*)os.getcwd\\(\\)" _ prefix)
                (string-append prefix maigret-dir-python))
               (("(db_file = .*)path.dirname\\(path.realpath\\(__file__\\)\\)" _ prefix)
                (string-append prefix maigret-dir-python))
               (("(db = MaigretDatabase\\(\\).load_from_path)\\(db_file\\)" all prefix)
                (format #f "try:~%        ~a~%    except:~%        ~a(path.join(path.dirname(path.realpath(__file__)), \"resources/data.json\"))" all prefix)))
             (substitute* "maigret/sites.py"
               (("import sys" all)
                (string-append all "\n" "import os"))
               (("with open\\(filename, \"w\"\\) as f:" all)
                (string-append "os.makedirs(os.path.dirname(filename), exist_ok=True)\n        " all)))))))
      (build-system pyproject-build-system)
      (propagated-inputs (list python-aiodns
                               python-aiohttp
                               python-aiohttp-socks
                               python-arabic-reshaper
                               python-async-timeout
                               python-attrs
                               python-certifi
                               python-chardet
                               python-colorama
                               python-future
                               ;; python-future-annotations
                               python-html5lib
                               python-idna
                               python-jinja2
                               python-lxml
                               python-markupsafe
                               python-mock
                               python-multidict
                               python-pycountry
                               python-pypdf2
                               python-pysocks
                               python-bidi
                               python-requests
                               python-requests-futures
                               python-six
                               python-socid-extractor
                               python-soupsieve
                               python-stem
                               python-torrequest
                               python-typing-extensions
                               python-alive-progress
                               python-webencodings
                               python-xhtml2pdf
                               python-xmind
                               python-yarl
                               python-networkx
                               python-pyvis
                               python-reportlab
                               python-cloudscraper))
      (native-inputs (list python-poetry-core
                           python-pytest))
      (arguments (list #:tests? #f))
      (home-page "https://github.com/soxoj/maigret")
      (synopsis
       "Collect a dossier on a person by username from a huge number of sites")
      (description
       "Collect a dossier on a person by username from a huge number of sites.")
      (license license:expat))))