semvec/pypi-packages huggingface dataset:
tracenl 0.1
Easily snoop on netlink messages with ptrace
License: MIT
Requires Python: >=3.6
Keywords: netlink capture trace

# Netlink Tracer

Netlink is a socket-based interface used for communication between the Linux
kernel and userspace applications.

`tracenl` is a proof-of-concept tool for monitoring and decoding Netlink
messages at a process level. It is implemented as a thin wrapper around
[python-ptrace](https://github.com/vstinner/python-ptrace) and
[pyroute2](https://pyroute2.org/).

## Installation

Install with `pip`:

```
$ pip install tracenl
```

## Usage

Typical usage:

```
$ tracenl -- iw dev

[4292] sendmsg(fd=3, msg=0x00007ffcc5215100, flags=0x0000000000000000) = 32 (0x0000000000000020)
  {'attrs': [('NL80211_ATTR_WIPHY_NAME', 'nl80211')],
   'cmd': 3,
   'header': {'flags': 5,
              'length': 32,
              'pid': 1786777796,
              'sequence_number': 1589321889,
              'type': 16},
   'reserved': 0,
   'version': 1}

[4292] recvmsg(fd=3, msg=0x00007ffcc5215090, flags=0x0000000000000022) = 2316 (0x000000000000090c)
  {'attrs': [('NL80211_ATTR_WIPHY_NAME', 'nl80211'),
             ('NL80211_ATTR_WIPHY', 29),
             ('NL80211_ATTR_IFINDEX', 1),
             ('NL80211_ATTR_IFNAME', ''),
             ('NL80211_ATTR_IFTYPE', 278),
             ('NL80211_ATTR_MAC', '14:00:01:00:08:00'),
             ('NL80211_ATTR_KEY_DATA', '....')],
...
```

## Limitations

In its current state, `tracenl` has significant limitations:

- Only decodes nl80211 messages.
- No support for attaching to running processes.
- Unattractive console output
xindi-lib 0.1.2
library to manage ip subnets
License: MIT

# xindi-lib

allows you to manage subnets of a network.
```
from xindi import ManagedNetwork
```

You can start with a dictionary
```
input_data = dict()
input_data['managed_network'] = '10.0.0.0/26'
managed_network = ManagedNetwork(indict=input_data)

```
or with JSON
```
input_data = '{"managed_network": "10.0.0.0/26"}'
managed_network = ManagedNetwork(injson=input_data)
```
assign new subnets of the needed size
```
my_first_net = dict(
    usecase='first network', 
    owner='Wolfgang Wangerin', 
    department='ITA'
    )
managed_network.next_free_subnet(27, my_first_net)
```
or free an existing subnet
```
managed_network.free('10.0.0.0/27')
```
list all assigned subnets:
```
managed_network.assigned_networks()
```
and export the configuration
```
outdict = managed_network.export()
outjson = managed_network.exportJson()
```

It is now up to you to set up an API or Webfrontend and use this library. Let me know, if you use this in an FOSS project, because I may have a usecase for it.
cloudgaze-cli 1.0.1
Convert CloudFormation templates to draw.io compatible diagrams, with dependency arrows
License: MIT

# cloudgaze-cli

![Documentation Status](https://readthedocs.org/projects/cloudgaze/badge/?version=latest)

Documentation can be found at https://cloudgaze.readthedocs.io/en/latest/

---

CLI (command line interface) to call the Cloudgaze API to transform your AWS cloudformation template specifications to draw.io compatible xml files.

This command line application makes a network call in the background to convert the template file. No data is stored on the remote endpoint, and you need to be connected to the internet to use this tool. The communication is encrypted using TLS.

## Install
`pip install cloudgaze-cli`

## Usage
```bash
$ cloudgaze --help
Usage: cloudgaze [OPTIONS] TEMPLATE_FILE OUTPUT_FILE

Options:
  --help  Show this message and exit.
```

```bash
$ cloudgaze ./path/to/template.yml ./path/to/output.xml
results written to '/abs/path/to/output.xml'
```

## Examples

For example, the analytics template file for the [AWS realworld serverless application example][1] will render the following diagram in draw.io:

![Example of analytics template output](docs/analytics_example.png)

To see the diagram in the above form, the output from cloudgaze have to be opened in draw.io or a compatible application. The diagram can then be modified in the application. 

The resources will be connected with arrows to indicate a dependency.

[1]: https://github.com/awslabs/realworld-serverless-application/blob/master/analytics/sam/app/template.yaml
chmod-monkey 1.1.1
Add support for `os.chmod('script.sh', 'ug+x')` syntax style.
License: MIT
Keywords: chmod monkeypatch str string

# python-chmod-monkey

[![PyPI](https://img.shields.io/pypi/v/chmod-monkey)](https://pypi.org/project/chmod-monkey/)
![PyPI - Python Version](https://img.shields.io/pypi/pyversions/chmod-monkey)
![PyPI - License](https://img.shields.io/pypi/l/chmod-monkey)
[![Build Status](https://img.shields.io/travis/Toilal/python-chmod-monkey.svg)](https://travis-ci.org/Toilal/python-chmod-monkey)
[![Code coverage](https://img.shields.io/coveralls/github/Toilal/python-chmod-monkey)](https://coveralls.io/github/Toilal/python-chmod-monkey)

Add support for `os.chmod('script.sh', 'ug+x')` syntax style.

Almost any expression supported by [GNU Coreutils chmod](https://linux.die.net/man/1/chmod) should be supported by this module.

**`[ugoa]*([-+=]([rwx]*|[ugo]))+|[-+=][0-7]+`**

`Xst` flags are not supported though.

## Install

```
pip install chmod-monkey
```

## Usage

There are two ways to use `chmod-monkey`.

### Using os.chmod MonkeyPatch

```python
import os

import chmod_monkey
chmod_monkey.install()  # Install monkeypatch because we are evil !

os.chmod('script.sh', 'ug+x')  # Magic :)
```

### Using to_mode converter

```python
import os

from chmod_monkey import to_mode

os.chmod('script.sh', to_mode('script.sh', 'ug+x'))  # For serious people.
```

## Other features

### Context manager

You may use the following syntax to temporary change a file mode.

```python
from chmod_monkey import tmp_chmod

with tmp_chmod('script.sh', "+w"):
    pass # File permissions are modified in this block only
# File permissions are restored here
```


History
=======

1.1.1 (2020-05-12)
------------------

- Add `exception_in_context` option to `tmp_chmod` and more data in context manager.


1.1.0 (2020-05-12)
------------------

- Add `tmp_chmod` function to temporary apply a permission on a file in a `with` statement.


1.0.0 (2020-05-11)
------------------

- First version