m-abc-anhnt


Namem-abc-anhnt JSON
Version 1.0.2 PyPI version JSON
download
home_pagehttps://github.com/mobiovn
SummaryThư viện xử lý kiểm tra quyền theo logic ABAC (Attribute-based access control)
upload_time2023-04-13 04:48:48
maintainer
docs_urlNone
authorMOBIO
requires_python>=3
licenseMIT
keywords mobio mobio-engine m-abac
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            ### ABAC Engine
Thư viện xử lý kiểm tra quyền theo logic ABAC (Attribute-based access control).


### Cài đặt:
```bash
 $ pip3 install m-abac
 ```

### Sử dụng:

##### 3. Save log action account:
   ```python
    from m_abac import PolicyDecisionPoint
    merchant_id = "1b99bdcf-d582-4f49-9715-1b61dfff3924"
    resource = "deal"
    # action = "UpdateFromSale"
    action = "ListFromSale"
    account_id = "704eac91-7416-497f-a17d-d81cfa2d3211"
    user_info = {
        "block": "KHDN",
        "scope_code": "MB##HN"
    }
    request_access = {
        "deal": {
            # "block": "KHCN",
            # "scope_code": "MB##HN##CAU_GIAY"
        }
    }

    pdb = PolicyDecisionPoint(merchant_id=merchant_id, resource=resource, action=action, account_id=account_id,
                              user_info=user_info, request_access=request_access)
    result = pdb.is_allowed()
    print("allow access: {}".format(result.get_allow_access()))
    print("display: {}".format(result.get_display_config()))
    print("filter: {}".format(result.get_filter_config()))
   ```
#### Log - 1.0.0
    - release sdk
    

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/mobiovn",
    "name": "m-abc-anhnt",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3",
    "maintainer_email": "",
    "keywords": "mobio,mobio-engine,m-abac",
    "author": "MOBIO",
    "author_email": "contact@mobio.vn",
    "download_url": "https://files.pythonhosted.org/packages/7f/e8/1e2254718d3fa7193249c224ecb176ea2aedeedb5f594d2e7aa251c80c27/m-abc-anhnt-1.0.2.tar.gz",
    "platform": null,
    "description": "### ABAC Engine\nTh\u01b0 vi\u1ec7n x\u1eed l\u00fd ki\u1ec3m tra quy\u1ec1n theo logic ABAC (Attribute-based access control).\n\n\n### C\u00e0i \u0111\u1eb7t:\n```bash\n $ pip3 install m-abac\n ```\n\n### S\u1eed d\u1ee5ng:\n\n##### 3. Save log action account:\n   ```python\n    from m_abac import PolicyDecisionPoint\n    merchant_id = \"1b99bdcf-d582-4f49-9715-1b61dfff3924\"\n    resource = \"deal\"\n    # action = \"UpdateFromSale\"\n    action = \"ListFromSale\"\n    account_id = \"704eac91-7416-497f-a17d-d81cfa2d3211\"\n    user_info = {\n        \"block\": \"KHDN\",\n        \"scope_code\": \"MB##HN\"\n    }\n    request_access = {\n        \"deal\": {\n            # \"block\": \"KHCN\",\n            # \"scope_code\": \"MB##HN##CAU_GIAY\"\n        }\n    }\n\n    pdb = PolicyDecisionPoint(merchant_id=merchant_id, resource=resource, action=action, account_id=account_id,\n                              user_info=user_info, request_access=request_access)\n    result = pdb.is_allowed()\n    print(\"allow access: {}\".format(result.get_allow_access()))\n    print(\"display: {}\".format(result.get_display_config()))\n    print(\"filter: {}\".format(result.get_filter_config()))\n   ```\n#### Log - 1.0.0\n    - release sdk\n    \n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "Th\u01b0 vi\u1ec7n x\u1eed l\u00fd ki\u1ec3m tra quy\u1ec1n theo logic ABAC (Attribute-based access control)",
    "version": "1.0.2",
    "split_keywords": [
        "mobio",
        "mobio-engine",
        "m-abac"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "93243fee62ac2c44114f91a83185ee4fafc4f1d4de23c9500269fb0a8b37f31f",
                "md5": "a5b6ec6d45a9c772e9aca693ba6a6fce",
                "sha256": "0d367e9ec64622a89dfc9faf099ad200a56253e315581e7b9821483e606850fb"
            },
            "downloads": -1,
            "filename": "m_abc_anhnt-1.0.2-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "a5b6ec6d45a9c772e9aca693ba6a6fce",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3",
            "size": 43064,
            "upload_time": "2023-04-13T04:48:46",
            "upload_time_iso_8601": "2023-04-13T04:48:46.192789Z",
            "url": "https://files.pythonhosted.org/packages/93/24/3fee62ac2c44114f91a83185ee4fafc4f1d4de23c9500269fb0a8b37f31f/m_abc_anhnt-1.0.2-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "7fe81e2254718d3fa7193249c224ecb176ea2aedeedb5f594d2e7aa251c80c27",
                "md5": "b52455c6b148c127e65ae07f7026c59a",
                "sha256": "3e935b0782dc0f28d25ea3a913d6b12786b784ae3223229d24e21b74128c84c9"
            },
            "downloads": -1,
            "filename": "m-abc-anhnt-1.0.2.tar.gz",
            "has_sig": false,
            "md5_digest": "b52455c6b148c127e65ae07f7026c59a",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3",
            "size": 21439,
            "upload_time": "2023-04-13T04:48:48",
            "upload_time_iso_8601": "2023-04-13T04:48:48.684688Z",
            "url": "https://files.pythonhosted.org/packages/7f/e8/1e2254718d3fa7193249c224ecb176ea2aedeedb5f594d2e7aa251c80c27/m-abc-anhnt-1.0.2.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-04-13 04:48:48",
    "github": false,
    "gitlab": false,
    "bitbucket": false,
    "lcname": "m-abc-anhnt"
}
        
Elapsed time: 0.09257s