Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@ryanohoro
Copy link
Collaborator

Describe the change

Adds OpenTelemetry integration to the backend. Allows end-users to view traces for requests processed by Strelka.

Adds a Jaeger all-in-one container for trace visualization.

Converts backend config parsing to a class BackendConfig to improve code re-use.

Modify __main__.py and strelka-backend to support BackendConfig class.

Move coordinator setup from strelka-backend to Backend class.

Removes the deletion of setuptools at build time, it's a runtime dependency.

Describe testing procedures

docker-compose -f build/docker-compose.yaml build
./strelka-oneshot -l - -f src/python/strelka/tests/fixtures/test.png

Navigate to http://localhost:16686/, choose the strelka.backend.worker Service. Click "Find Traces".

Observe a trace returned in results.

cd src/python
python setup.py install
cd ../..
strelka src/python/strelka/tests/fixtures/test.html
starting local analysis...
{"file": {"depth": 0, "flavors": {"mime": ["text/html"], "yara": ["html_file"]}, "name": "src/python/strelka/tests/fixtures/test.html", "scanners": ["ScanEntropy", "ScanFooter", "ScanHash", "ScanHeader", "ScanHtml", "ScanYara"], "size": 5875, "tree": {"node": "757eceff-d941-4a58-b292-1bbe2b96dc29", "root": "757eceff-d941-4a58-b292-1bbe2b96dc29"}}, "scan": {"entropy": {"elapsed": 5.5e-05, "entropy": 4.847574566795829}, "footer": {"elapsed": 2.5e-05, "footer": "pan></span>\n</p>\n\n\n<p>&nbsp;</p>\n\n\n</body>\n</html>"

Sample output

image

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

Copy link
Contributor

@phutelmyer phutelmyer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great, tested great. Didn't seem to run into any problems.

@phutelmyer phutelmyer merged commit f334811 into target:master Feb 15, 2023
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.

2 participants