Skip to content
This repository has been archived by the owner on May 12, 2022. It is now read-only.

Failure on database update - NIST XML feed retirement #16

Closed
U039b opened this issue Dec 13, 2019 · 3 comments
Closed

Failure on database update - NIST XML feed retirement #16

U039b opened this issue Dec 13, 2019 · 3 comments
Labels
Milestone

Comments

@U039b
Copy link

U039b commented Dec 13, 2019

I am not able to update the database due to NIST XML feed retirement.

The following error occured when I try to update the database:

$ patton-server -C postgres://patton:patton@127.0.0.1:5432/patton update-db
    > official-cpe-dictionary_v2.3.xml.gz: 6.60MB [00:01, 5.74MB/s]                                                                                                                                                                                                                                                                                                                                                                        
    > nvdcve-2.0-recent.xml.gz: 28.7kB [00:00, 3.80MB/s]                                                                                                                                                                                                                                                                                                                                                                                   
Traceback (most recent call last):
  File "/tmp/venv/bin/patton-server", line 8, in <module>
    sys.exit(main())
  File "/tmp/venv/lib/python3.7/site-packages/patton_server/command_line.py", line 129, in main
    update_db(**config)
  File "/tmp/venv/lib/python3.7/site-packages/patton_server/dal/updater.py", line 86, in update_db
    web_hook))
  File "/usr/lib/python3.7/asyncio/base_events.py", line 584, in run_until_complete
    return future.result()
  File "/tmp/venv/lib/python3.7/site-packages/patton_server/dal/updater.py", line 59, in _update_db
    only_last_cve=True)
  File "/tmp/venv/lib/python3.7/site-packages/patton_server/dal/loader.py", line 97, in download_assets
    shutil.copyfileobj(f_in, f_out)
  File "/tmp/venv/lib/python3.7/shutil.py", line 79, in copyfileobj
    buf = fsrc.read(length)
  File "/usr/lib/python3.7/gzip.py", line 276, in read
    return self._buffer.read(size)
  File "/usr/lib/python3.7/_compression.py", line 68, in readinto
    data = self.read(len(byte_view))
  File "/usr/lib/python3.7/gzip.py", line 463, in read
    if not self._read_gzip_header():
  File "/usr/lib/python3.7/gzip.py", line 411, in _read_gzip_header
    raise OSError('Not a gzipped file (%r)' % magic)
OSError: Not a gzipped file (b'<!')
@U039b
Copy link
Author

U039b commented Dec 13, 2019

Seemed to be related to #15.

@cr0hn
Copy link
Contributor

cr0hn commented Dec 13, 2019

Coming soon update is planned, but we have not a date

@cr0hn cr0hn added the bug label Jan 21, 2020
@cr0hn cr0hn added this to the Patton2 milestone Jan 21, 2020
@hhurtado
Copy link
Contributor

hhurtado commented Oct 2, 2020

Related to deprecated v1.

@hhurtado hhurtado closed this as completed Oct 2, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

3 participants