{ "info": { "author": "SAP SE", "author_email": "secure@sap.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 5 - Production/Stable", "License :: OSI Approved :: Apache Software License", "Natural Language :: English", "Operating System :: MacOS :: MacOS X", "Operating System :: Microsoft :: Windows", "Operating System :: POSIX", "Operating System :: POSIX :: BSD", "Operating System :: POSIX :: Linux", "Programming Language :: Python", "Programming Language :: Python :: 2", "Programming Language :: Python :: 2.7", "Programming Language :: Python :: 3", "Programming Language :: Python :: 3.4", "Programming Language :: Python :: 3.5", "Programming Language :: Python :: 3.6", "Programming Language :: Python :: 3.7", "Programming Language :: Python :: Implementation :: CPython", "Programming Language :: Python :: Implementation :: PyPy", "Topic :: Security" ], "description": "# cloud-sapjwt\n==============\n\nJSON Web Token (JWT) offline validation for SAPCP client applications with current binaries of SAPJWT verification library.\n\nThis project contains the JWT binding. It also includes the native libraries to run on XSA platforms. \nIf you need another platforms, please write to the author.\n\n# Platforms\n\nSupported platforms: Windows | Linux | MacOS\n\nThis package contains a ctypes based wrapper for Python to use SAPJWT library\n\n#### Hello World\n\nThis standard example is from http://jwt.io \n\n```python\n import sapjwt\n \n jwtver = sapjwt.jwtValidation()\n \n print(\"SAPJWT version : \" + jwtver.getLibraryVersion())\n \n jwtver.setVerificationKey(\"secret\")\n _rc = jwtver.checkToken(\"eyJhbGciOiJIUzI1NiIsImtpZCI6InRlc3QiLCJ0eXAiOiJKV1QifQ.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiYWRtaW4iOmZhbHNlfQ.b2CDs7y56N9VWUh6wpLBdws-6omVyihJhpnBB7MdHCw\")\n\n if _rc != 0:\n print(\"Validation error: \" + jwtver.getErrorDescription())\n else:\n print(\"Validation key-Id from JWT: \" +jwtver.getKeyId())\n print(\"Validation succeeded, payload from JWT: \" + jwtver.getPayload())\n\n```\n\n# Getting started\n\nThis project should not be included but you should include sap_xssec as API project. This project provides a wrapper to the native \nvalidation library for JWT.\nFrom your project directory, run (see below for requirements):\n\n```python\n from sap import xssec\n```\n\n# Error situations\n\nThe standard error for signature operations is the situation, that the signature is not valid. This error is typical and you should handle\nit carefully! and not as fatal error or assert.\nIf you think, it must work, but it does not, then you can trace the native functions.\nSAPSSOEXT library allows you to set the environment variables:\n* SAP_EXT_TRC to define a trace file in your file system\n* SAP_EXT_TRL an integer 0 to 3\n\n```\nset SAP_EXT_TRC=stdout\nset SAP_EXT_TRL=3\n```\n\nIf you run your application in CloudFoundry or XSA then you can define environment variables with client command tool cf / xs, see\nhttps://docs.run.pivotal.io/devguide/deploy-apps/manifest.html#env-block \n\nIn cf landscapes you can then cf logs and you will see trace from JWT validation\n\n\n# Install via pip\n\nIn order to configure the sap pypi registry you need to issue the following command:\n\n```\npip install --user sap_xssec\n```\n\nIf you have not yet configured any sap pypi registry use this call:\n\n```\npip install sap_xssec\n```\n\n# CF Deployment \n\nThe deployment of python code to cloudfoundry executes 'pip install'. The package sap_xssec vendor dependent package which means it is not available in public repositories. The solution for this is a deployment with a local vendor folder, see\nhttps://docs.cloudfoundry.org/buildpacks/python/index.html#vendoring \n\nYour application should have a so called requirements.txt file. In this file you define your dependencies, e.g. sap_xssec (this package includes sap_py_jwt). So before a push to cf you create a local vendor folder and put all dependend binaries into this folder.\n\nThe push command uploads the complete local folder to CF and the python buildpack then installs the private packages from the vendor folder.\n\n# Known issues\nThis project provide binary language bindings for cloud platforms. Linux x64 can be used in docker images which depend on Debian derivates of Linux. There is currently no Alpine binary available, because of different linker, see https://www.musl-libc.org/.\n\n# License\nCopyright (c) 2019 SAP SE or an SAP affiliate company. All rights reserved. This project is licensed under the SAP Sample Code License, except as noted otherwise in the [LICENSE](LICENSE) file.", "description_content_type": "text/markdown", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/SAP-samples/cloud-sapjwt", "keywords": "sap jwt sapjwt python", "license": "SAP Developer", "maintainer": "", "maintainer_email": "", "name": "sap-py-jwt", "package_url": "https://pypi.org/project/sap-py-jwt/", "platform": "", "project_url": "https://pypi.org/project/sap-py-jwt/", "project_urls": { "Homepage": "https://github.com/SAP-samples/cloud-sapjwt" }, "release_url": "https://pypi.org/project/sap-py-jwt/1.5.0/", "requires_dist": null, "requires_python": "", "summary": "SAP CP Security Client Library for JWT offline validation", "version": "1.5.0" }, "last_serial": 5509243, "releases": { "1.5.0": [ { "comment_text": "", "digests": { "md5": "67f2a3ea22649d51668c0bd168973560", "sha256": "183fe8453f7bafc0543a622ebd514ca96c7bfca325db3aeef255c578f8e914fd" }, "downloads": -1, "filename": "sap_py_jwt-1.5.0.tar.gz", "has_sig": false, "md5_digest": "67f2a3ea22649d51668c0bd168973560", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 559013, "upload_time": "2019-07-09T21:40:18", "url": "https://files.pythonhosted.org/packages/1b/ad/503b320d4dd330ad6b71447dc891fde1de52234f30a436196d68875e9ed7/sap_py_jwt-1.5.0.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "67f2a3ea22649d51668c0bd168973560", "sha256": "183fe8453f7bafc0543a622ebd514ca96c7bfca325db3aeef255c578f8e914fd" }, "downloads": -1, "filename": "sap_py_jwt-1.5.0.tar.gz", "has_sig": false, "md5_digest": "67f2a3ea22649d51668c0bd168973560", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 559013, "upload_time": "2019-07-09T21:40:18", "url": "https://files.pythonhosted.org/packages/1b/ad/503b320d4dd330ad6b71447dc891fde1de52234f30a436196d68875e9ed7/sap_py_jwt-1.5.0.tar.gz" } ] }