Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ScanDocx Datetime Updates and OneNote File Emit Change #314

Merged
merged 4 commits into from
Feb 8, 2023

Conversation

phutelmyer
Copy link
Contributor

@phutelmyer phutelmyer commented Feb 7, 2023

Describe the change
This change:

  • Updates the datetime emitted by ScanDocx from an integer to an ISO timestamp.
  • Replaced file extraction code from ScanOnenote with shared emit_file function.

Describe testing procedures
docker-compose -f build/docker-compose.yaml build --build-arg CONFIG_TESTS=true backend

[+] Building 102.8s (24/24) FINISHED                                                                                                                                                                                                                                                                                                               
 => [internal] load build definition from Dockerfile                                                                                                                                                                                                                                                                                          0.0s
 => => transferring dockerfile: 32B                                                                                                                                                                                                                                                                                                           0.0s
 => [internal] load .dockerignore                                                                                                                                                                                                                                                                                                             0.0s
 => => transferring context: 34B                                                                                                                                                                                                                                                                                                              0.0s
 => [internal] load metadata for docker.io/library/ubuntu:22.04                                                                                                                                                                                                                                                                               1.3s
 => [ 1/19] FROM docker.io/library/ubuntu:22.04@sha256:9a0bdde4188b896a372804be2384015e90e3f84906b750c1a53539b585fbbe7f                                                                                                                                                                                                                       0.0s
 => [internal] load build context                                                                                                                                                                                                                                                                                                             0.1s
 => => transferring context: 84.11kB                                                                                                                                                                                                                                                                                                          0.1s
 => CACHED [ 2/19] RUN groupadd --gid 1001 strelka     && useradd --uid 1001 --gid 1001 --create-home --shell /bin/bash strelka                                                                                                                                                                                                               0.0s
 => CACHED [ 3/19] COPY ./build/python/backend/pin.pref /etc/apt/preferences.d/pin.pref                                                                                                                                                                                                                                                       0.0s
 => CACHED [ 4/19] COPY ./build/python/backend/kinetic.list /etc/apt/sources.list.d/kinetic.list                                                                                                                                                                                                                                              0.0s
 => CACHED [ 5/19] RUN apt-get -q update &&     apt-get install -q -y --no-install-recommends     automake     build-essential     cmake     curl     gcc     git     gpg     libglu1-mesa     libtool     make     swig     python3-dev     python3-pip     python3-wheel     python-is-python3     pkg-config                               0.0s
 => CACHED [ 6/19] RUN echo 'deb http://download.opensuse.org/repositories/security:/zeek/xUbuntu_22.04/ /' | tee /etc/apt/sources.list.d/security:zeek.list &&     curl -fsSL https://download.opensuse.org/repositories/security:zeek/xUbuntu_22.04/Release.key | gpg --dearmor | tee /etc/apt/trusted.gpg.d/security_zeek.gpg > /dev/null  0.0s
 => CACHED [ 7/19] RUN apt-get -q update &&     apt-get install -q -y --no-install-recommends     7zip     antiword     binwalk     libarchive-dev     libcompress-raw-lzma-perl     libfuzzy-dev     libjansson-dev     libmagic-dev     libssl-dev     libzbar0     libgl1     python3-setuptools     redis-server     tesseract-ocr     u  0.0s
 => CACHED [ 8/19] RUN apt-mark manual zeek-lts                                                                                                                                                                                                                                                                                               0.0s
 => CACHED [ 9/19] RUN apt-get -q update   && apt-get install -q -y --no-install-recommends     ca-certificates     libssl-dev     zlib1g-dev     yasm     libgmp-dev     libpcap-dev     libbz2-dev     libgomp1                                                                                                                             0.0s
 => CACHED [10/19] RUN mkdir jtr && cd jtr && git init && git remote add origin https://github.com/openwall/john.git && git fetch --depth 1 origin b5c10480f56ff1b5d76c6cbdaf9c817582ee2228 && git reset --hard FETCH_HEAD   && rm -rf /jtr/.git   && cd /jtr/src   && ./configure   && make -s clean   && make -sj4   && make install   &&   0.0s
 => CACHED [11/19] COPY ./build/python/backend/requirements.txt /strelka/requirements.txt                                                                                                                                                                                                                                                     0.0s
 => CACHED [12/19] RUN pip3 install --no-cache-dir -r /strelka/requirements.txt &&     pip3 install --index-url https://lief-project.github.io/packages --trusted-host lief.quarkslab.com lief                                                                                                                                                0.0s
 => [13/19] COPY ./src/python/ /strelka/                                                                                                                                                                                                                                                                                                      0.4s
 => [14/19] COPY ./build/python/backend/setup.py /strelka/setup.py                                                                                                                                                                                                                                                                            0.0s
 => [15/19] COPY ./configs/python/backend/ /etc/strelka/                                                                                                                                                                                                                                                                                      0.0s
 => [16/19] RUN cd /strelka/ &&     python3 setup.py -q build &&     python3 setup.py -q install &&     python3 setup.py -q clean --all &&     rm -rf dist/ strelka.egg-info &&     pip3 uninstall -y grpcio-tools &&     apt-get remove -y --purge     automake     build-essential     cmake     curl     gcc     git     gpg     libtool   9.4s
 => [17/19] RUN echo '[+] Run build checks' &&     cd /strelka/strelka/ &&     python3 -m pytest -s tests/ &&     if true; then python3 -m pytest -s tests_configuration/; fi &&     echo '[+] Done'                                                                                                                                         90.4s
 => [18/19] RUN cd /strelka/ &&     rm -rf /strelka/                                                                                                                                                                                                                                                                                          0.4s
 => [19/19] RUN rm -rf /etc/strelka/                                                                                                                                                                                                                                                                                                          0.4s
 => exporting to image                                                                                                                                                                                                                                                                                                                        0.3s
 => => exporting layers                                                                                                                                                                                                                                                                                                                       0.3s
 => => writing image sha256:7c84f6ee539f4f06e465a66867fd3822ebecba876bfe6336300067ea0e451a8a                                                                                                                                                                                                                                                  0.0s
 => => naming to docker.io/library/build-backend  

Sample output
Changes to the ScanDocx can be observed below:

{
     ...
      -  'created': 1671208080,
      +  'created': '2022-12-16T16:28:00',
      ...
      -  'modified': 1671209040,
      +  'modified': '2022-12-16T16:44:00',
}

Checklist

  • My code follows the style guidelines of this project
  • I have performed a self-review of and tested my code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings

@phutelmyer phutelmyer merged commit 8d590dd into master Feb 8, 2023
@phutelmyer phutelmyer deleted the datetime-updates-and-onenote-change branch March 28, 2023 13:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant