Title: DoD file submission only accepts utf-8 encoded files · Issue #2 · fireeye/fireeye-python · GitHub
Open Graph Title: DoD file submission only accepts utf-8 encoded files · Issue #2 · fireeye/fireeye-python
X Title: DoD file submission only accepts utf-8 encoded files · Issue #2 · fireeye/fireeye-python
Description: You can't submit PDF, PNG, or other non utf-8 encoded files. Need to support all filetypes. Here is the error I received when trying to submit a PNG file: response = detection.submit_file(files={"file": ('filename', open('./fireeyelogo-v...
Open Graph Description: You can't submit PDF, PNG, or other non utf-8 encoded files. Need to support all filetypes. Here is the error I received when trying to submit a PNG file: response = detection.submit_file(files={"f...
X Description: You can't submit PDF, PNG, or other non utf-8 encoded files. Need to support all filetypes. Here is the error I received when trying to submit a PNG file: response = detection.submit_file(files...
Opengraph URL: https://github.com/fireeye/fireeye-python/issues/2
X: @github
Domain: github.com
IPv4 address: 140.82.114.3
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"DoD file submission only accepts utf-8 encoded files","articleBody":"You can't submit PDF, PNG, or other non utf-8 encoded files. Need to support all filetypes. Here is the error I received when trying to submit a PNG file:\r\n\r\n>>> response = detection.submit_file(files={\"file\": ('filename', open('./fireeyelogo-vector.png', 'r'))})\r\nTraceback (most recent call last):\r\n File \"\u003cstdin>\", line 1, in \u003cmodule>\r\n File \"/usr/local/lib/python3.7/site-packages/fireeyepy/__init__.py\", line 75, in submit_file\r\n return self.post(self.api_host, \"/files\", body, files)\r\n File \"/usr/local/lib/python3.7/site-packages/fireeyepy/__init__.py\", line 108, in post\r\n return self.parse(host, self.session.post(uri, data=data, files=files, headers=headers))\r\n File \"/usr/local/lib/python3.7/site-packages/requests/sessions.py\", line 581, in post\r\n return self.request('POST', url, data=data, json=json, **kwargs)\r\n File \"/usr/local/lib/python3.7/site-packages/requests/sessions.py\", line 519, in request\r\n prep = self.prepare_request(req)\r\n File \"/usr/local/lib/python3.7/site-packages/requests/sessions.py\", line 462, in prepare_request\r\n hooks=merge_hooks(request.hooks, self.hooks),\r\n File \"/usr/local/lib/python3.7/site-packages/requests/models.py\", line 316, in prepare\r\n self.prepare_body(data, files, json)\r\n File \"/usr/local/lib/python3.7/site-packages/requests/models.py\", line 504, in prepare_body\r\n (body, content_type) = self._encode_files(files, data)\r\n File \"/usr/local/lib/python3.7/site-packages/requests/models.py\", line 159, in _encode_files\r\n fdata = fp.read()\r\n File \"/usr/local/Cellar/python/3.7.4_1/Frameworks/Python.framework/Versions/3.7/lib/python3.7/codecs.py\", line 322, in decode\r\n (result, consumed) = self._buffer_decode(data, self.errors, final)\r\nUnicodeDecodeError: 'utf-8' codec can't decode byte 0x89 in position 0: invalid start byte","author":{"url":"https://github.com/mckibbenc","@type":"Person","name":"mckibbenc"},"datePublished":"2019-11-19T21:08:21Z","url":"https://github.com/fireeye/fireeye-python/issues/2"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:62054d6b-8bd5-b6a6-e896-6ed5e96a94eb |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | 9308:3ABA9B:C72C6D:FD769F:6B08BD9B |
| html-safe-nonce | 6d8872fa2fbc7d057e181281cee4f169fab6970de69aec9b4ca9aee210f4522f |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI5MzA4OjNBQkE5QjpDNzJDNkQ6RkQ3NjlGOjZCMDhCRDlCIiwidmlzaXRvcl9pZCI6IjE1OTMyMzg4MjE5ODkzMDE2NTkiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | 1e57f44d83a467ee771bac774651758419feef34db0948bfa5027c57dd8a8a55 |
| hovercard-subject-tag | issue:525268671 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/fireeye/fireeye-python/2/issue_layout |
| twitter:image | https://opengraph.githubassets.com/fe86baf96db4802d94e03e219d80a1d546b3395b8d1191cc0a986e9eb5bcc04a/fireeye/fireeye-python/issues/2 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/fe86baf96db4802d94e03e219d80a1d546b3395b8d1191cc0a986e9eb5bcc04a/fireeye/fireeye-python/issues/2 |
| og:image:alt | You can't submit PDF, PNG, or other non utf-8 encoded files. Need to support all filetypes. Here is the error I received when trying to submit a PNG file: response = detection.submit_file(files={"f... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | mckibbenc |
| hostname | github.com |
| expected-hostname | github.com |
| None | 60e86161f3e246339ce8d4bd308e3da0ecd5ebd5e610d57e00d21487fe085d68 |
| turbo-cache-control | no-preview |
| go-import | github.com/fireeye/fireeye-python git https://github.com/fireeye/fireeye-python.git |
| octolytics-dimension-user_id | 4984788 |
| octolytics-dimension-user_login | fireeye |
| octolytics-dimension-repository_id | 210075919 |
| octolytics-dimension-repository_nwo | fireeye/fireeye-python |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 210075919 |
| octolytics-dimension-repository_network_root_nwo | fireeye/fireeye-python |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | e87e2b0f8aff9e45b7ac6c81be5a939ad971830c |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
| Server | github.com |
| Content-Type | text/html; charset=utf-8 |
| Cache-Control | max-age=0, private, must-revalidate |
Viewport: width=device-width