semvec/pypi-packages huggingface dataset:
ecceran 0.1.1
Simple ECC encrypt decrypt
Requires Python: >=3.9,<4.0

# Ecceran

simple ECC encrypt & decrypt

### Install

`$ pip install ecceran`

### Generate Private Key

run `ecceran` in your command line for generate new secret key in `.private_key`

```

$ ecceran

public key : 02a4610d81d6c522ae67c2570********

```
the public key will be used to decrypt. `generate` command will return public key from file `.private_key`, to re-generate need to delete file `private_key`

### Get Private Key

```python

from ecceran import private_key



private_key_app = private_key()

# 5xa46gg0d81d6c522ae9ku2570********

  

```

### Encrypt & Decrypt

```python

from ecceran import encrypt, decrypt, private_key



pubkey = '02a4610d81d6c522ae67c2570********'

enc_data = encrypt(pubkey, b'test')

print(enc_data)

# d2zx4d81d6xxx2va67c24470********

  

prikey = private_key()

byte = bytes.fromhex(enc_data)

dec_data = decrypt(prikey, byte)

print(dec_data)

# b'test'

```
django-recyclebin 0.2
A Django app to make recyclebin.
Requires Python: >=3.6

=====
Django Recyclebin
=====

Django Recyclebin is a Django app to create recyclebin functionality in your project. you will be able to temporarily delete, restore and permanently delete data.


Quick start
-----------

1. Add "recyclebin" to your INSTALLED_APPS setting like this::

    INSTALLED_APPS = [
        ...
        'recyclebin',
    ]

2. import SoftDeleteMixin ''from recyclebin.models import SoftDeleteMixin''

3. Inherit your model with SoftDeleteMixin

        ``class Mymodel(SoftDeleteMixin)``

4. Run ``python manage.py makemigrations``  and ``python manage.py migrate``.

5. import recyclebin functions ``from recyclebin.functions import get_deleted_items, restore, permanent_delete``

6. How to temporarily delete.
    you don't need to do anything. after inheriting your model with SoftDeleteMixin. your regular .delete() method will temporarily delete objects

7. How to view deleted items 
    create a list of models
    from myapp.models import Model1, Model2, Model3...
    li = [Model1, Model2, Model3...]
     ``get_deleted_items(li)``

    ''This function will return serialized response that will contain model_name, name, pk, deleted_by, deleted_at''
    
    YOUR MODEL MUST HAVE NAME FIELD OTHERWISE NONE WILL BE RETURNED INSTEAD OF NAME

8. How to restore
    pass restore function model name and id. model name must be string and id an integer
    ``restore(model1, 1)``

9. How to permanently delete
    pass permanent_delete function model name and id. model name must be string and id an integer
    ``permanent_delete(model1, 1)``