Skip to main content

Semantic strings based on tree-sitter

Project description

pyscrings

Python bindings for scrings powered by PyO3 and maturin

scrings is a strings utility that will output only semantically valid strings based on tree-sitter grammar. For each script language we made a list of semantic nodes discriminant enough to detect the target language.

Install

pyscrings is available on PyPi:

pip install pyscrings

Usage

from pyscrings import powershell, javascript, php, bash, python, sql

with open("path_to_dump", "rb") as f:
    for (offset, match) in powershell(f):
        print((offset, repr(match)))

Supported languages

Build

pyscrings is powered by maturin

git clone https://github.com/airbus-cert/scrings
cd scrings\pyscrings

pip install maturin
maturin build --profile release

pip install target\wheels\*.whl

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

pyscrings-0.1.3-cp38-abi3-win_amd64.whl (997.9 kB view details)

Uploaded CPython 3.8+Windows x86-64

pyscrings-0.1.3-cp38-abi3-manylinux_2_28_x86_64.whl (1.2 MB view details)

Uploaded CPython 3.8+manylinux: glibc 2.28+ x86-64

File details

Details for the file pyscrings-0.1.3-cp38-abi3-win_amd64.whl.

File metadata

  • Download URL: pyscrings-0.1.3-cp38-abi3-win_amd64.whl
  • Upload date:
  • Size: 997.9 kB
  • Tags: CPython 3.8+, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.10.5

File hashes

Hashes for pyscrings-0.1.3-cp38-abi3-win_amd64.whl
Algorithm Hash digest
SHA256 d93bee373d429d975316d921500ad2168712ffa5dc0eaa4a1e27f716983c833a
MD5 9a9f97b1087dc68013f0e5c8da8de7d6
BLAKE2b-256 3e0b5f28511f59c298cf918498d18336f156d4d6259d2abfefda7be186bad9b9

See more details on using hashes here.

File details

Details for the file pyscrings-0.1.3-cp38-abi3-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for pyscrings-0.1.3-cp38-abi3-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 949894d6aa6964b4295486c3d27ced18972ee828aa0d8feb1dfc43576bbe22aa
MD5 be31659b7f1858f66b89e7351b9e630f
BLAKE2b-256 65b05c5c09ba8476c10aa478209088633db8e6f9b678476e76e8ec8ff8231e05

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page