Metadata-Version: 2.3
Name: oamp-ipaddress
Version: 0.1.0
Summary: 
License: MIT
Author: Mike Simkins
Author-email: software@g7software.dev
Requires-Python: >=3.10
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Requires-Dist: django (>4.2,<5)
Description-Content-Type: text/markdown

# OAMP-IPADDRESS

This is a Django Field to hold IP Addresses.
It serializes to a CharField, so it will work with all
database backends.

The field will process the following IP Addressing formats:

- Bare IP Address

    A standard IPv4 Address, or IPv6 Address (ex. 192.168.1.1 or 2001:db8:202:303::1)

- CIDR Notation

    A standard CIDR Notation (ex.192.168.1.1/24 or 2001:db8:202:303::1/64)

- Bare IP Address with (Optional routing instance (VRF)

    A standard IPv4 Address, or IPv6 Address with an optional VRF (ex. 192.168.1,1@personal_vrf or 2001:db8:202:303::1@personal_vrf)

- CIDR Notation with (Optional routing instance (VRF)

    A standard CIDR Notation with an optional VRF (ex. 192.168.1.1/24@another_vrf or 2001:db8:202:303::1/64@another_vrf)


The vrf name is currently limited to 63 characters, which should cover the vast majority of network vendor VRF names.


## Installation

```bash
pip install oamp-ipaddress
```

## Usage

```python
from django.db import models
from oamp_ipaddress.fields import SortableIPAddressField

class MyModel(models.Model):
    ip = SortableIPAddressField()


```

## Testing

```bash
python manage.py test
```

## License

This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details

## Contributing

Please read [CONTRIBUTING.md](CONTRIBUTING.md) for details on our code of conduct, and the process for submitting pull requests to us.

## Copyright

This project is Copyright (c) 2025 by Mike Simkins, All Rights Reserved
```

