Skip to main content

Python Cursor On Target Object-Relational Mapper

Project description

PyCot

Python Cursor on Target Library

Summary

PyCot is developed to assist and streamline integration with programs that utilize Cursor on Target (CoT). This tool seeks to help generate, validate, and parse XML data that is defined from either MITRE or the MIL-STD.

Why?

I needed an easy way to interface with CoT messages, I could not find one available.

Usage

pipx install PyCot
import CoT
import datetime
import socket

now = datetime.datetime.now(datetime.timezone.utc)
stale = now + datetime.timedelta(minutes=2)

# Generate new Cursor on Target Event
py_cot = CoT.Event(
    version="2.0",
    type="a-u-G-U-U-S-R-S",
    access="Undefined",
    uid="Debug.Python",
    time=now,
    start=now,
    stale=stale,
    how="h-g-i-g-o",
    qos="2-i-c",
    point=CoT.Point(lat=90, lon=90, hae=9999999, ce=9999999, le=9999999),
    detail={"contact": {"callsign": "Debug.Python"}},
)

# Your TAK IPv4 / Port
TAK_IP = "x.x.x.x"
TAK_PORT = 9000

# Sending UDP -> TAK Insecure Anonymous Port
sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
sock.connect((TAK_IP, TAK_PORT))

sock.sendall(bytes(py_cot.xml(), encoding="utf-8"))

Project details


Download files

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

Source Distribution

pycot-3.0.1.tar.gz (25.1 kB view details)

Uploaded Source

Built Distribution

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

pycot-3.0.1-py3-none-any.whl (24.7 kB view details)

Uploaded Python 3

File details

Details for the file pycot-3.0.1.tar.gz.

File metadata

  • Download URL: pycot-3.0.1.tar.gz
  • Upload date:
  • Size: 25.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for pycot-3.0.1.tar.gz
Algorithm Hash digest
SHA256 589850821dce09d6e437c78eab5812a79651759b5ca24434832a47d2b44537bd
MD5 d9501bbf0b42f78c2184e89243b30f48
BLAKE2b-256 678786ce7a30d864b91c128c4e95f34501bab4011c69d40e2512f05e63162b07

See more details on using hashes here.

Provenance

The following attestation bundles were made for pycot-3.0.1.tar.gz:

Publisher: pypi-publish.yml on wcrum/py-cot

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file pycot-3.0.1-py3-none-any.whl.

File metadata

  • Download URL: pycot-3.0.1-py3-none-any.whl
  • Upload date:
  • Size: 24.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for pycot-3.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 48d66b2d3d1816416d78e6fcad5c459f91b4f84495102b55066898cae5bf7c93
MD5 433984b4dd35f7685d1ce3f46d0d6941
BLAKE2b-256 bc3988c9fdfedc2c7e431c786b4914b83e4c9aa97d7cdc58ac2940c882d4bafa

See more details on using hashes here.

Provenance

The following attestation bundles were made for pycot-3.0.1-py3-none-any.whl:

Publisher: pypi-publish.yml on wcrum/py-cot

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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