.. image:: https://img.shields.io/pypi/v/fortifyapi.svg
.. image:: https://img.shields.io/pypi/pyversions/fortifyapi.svg
.. image:: https://img.shields.io/circleci/build/github/fortifyadmin/fortifyapi/master?logo=CircleCI
Fortify API
***********
Fortify API is a Python RESTFul API client module for Fortify's `Software Security Center <https://www.microfocus.com/en-us/products/software-security-assurance-sdlc/overview/>`_
Quick Start
~~~~~~~~~~~
Several quick start options are available:
- Build locally: ``pip install wheel setuptools && python setup.py build``
- Install with pip (recommended): ``pip install fortifyapi``
- `Download the latest release <https://pypi.org/project/fortifyapi/>`__.
Example
~~~~~~~
.. code:: python
from os import environ
from locale import LC_ALL, setlocale
from fortifyapi.fortify import FortifyApi
# Set encoding
environ["PYTHONIOENCODING"] = "utf-8"
myLocale = setlocale(category=LC_ALL, locale="en_GB.UTF-8")
# Set vars for connection
url = 'https://some-fortify-host/ssc'
user = 'Fortify SSC User'
password = 'Fortify SSC Password'
description = 'fortifyapi test client'
# Authenticate and retrieve token
def token():
api = FortifyApi(host=url, username=user, password=password, verify_ssl=False)
response = api.get_token(description=description)
return response.data['data']['token']
# Re-use token in all requests
def api():
api = FortifyApi(host=url, token=token(), verify_ssl=False)
return api
# List ID, Project/application Version
def list():
response = api().get_all_project_versions()
data = response.data['data']
for version in data:
print("{0:8} {1:30} {2:30}".format(version['id'], version['project']['name'], version['name']).encode(
'utf-8', errors='ignore').decode())
if __name__ == '__main__':
list()
Bugs and Feature Requests
~~~~~~~~~~~~~~~~~~~~~~~~~
Found something that doesn't seem right or have a feature request? Please open a new issue.
Copyright and License
~~~~~~~~~~~~~~~~~~~~~
.. image:: https://img.shields.io/github/license/fortifyadmin/fortifyapi.svg?style=flat-square
Raw data
{
"_id": null,
"home_page": "https://github.com/fortifyadmin/fortifyapi",
"name": "fortifyapi",
"maintainer": null,
"docs_url": null,
"requires_python": null,
"maintainer_email": null,
"keywords": "fortify, api, security, software, microfocus, ssc, sast",
"author": "Brandon Spruth, Matthew Gill",
"author_email": "brandon@spruth.co, mgill@c0ffee.me",
"download_url": "https://files.pythonhosted.org/packages/19/23/ccafecba7d0ba74890b21ab0fe503f87a87c12040f2cbe48c77ac4ed60b9/fortifyapi-3.1.20.tar.gz",
"platform": null,
"description": ".. image:: https://img.shields.io/pypi/v/fortifyapi.svg\n.. image:: https://img.shields.io/pypi/pyversions/fortifyapi.svg\n.. image:: https://img.shields.io/circleci/build/github/fortifyadmin/fortifyapi/master?logo=CircleCI\n\nFortify API\n***********\n\nFortify API is a Python RESTFul API client module for Fortify's `Software Security Center <https://www.microfocus.com/en-us/products/software-security-assurance-sdlc/overview/>`_\n\nQuick Start\n~~~~~~~~~~~\n\nSeveral quick start options are available:\n\n- Build locally: ``pip install wheel setuptools && python setup.py build`` \n- Install with pip (recommended): ``pip install fortifyapi``\n- `Download the latest release <https://pypi.org/project/fortifyapi/>`__.\n\nExample\n~~~~~~~\n\n.. code:: python\n\n from os import environ\n from locale import LC_ALL, setlocale\n from fortifyapi.fortify import FortifyApi\n \n # Set encoding\n environ[\"PYTHONIOENCODING\"] = \"utf-8\"\n myLocale = setlocale(category=LC_ALL, locale=\"en_GB.UTF-8\")\n \n # Set vars for connection\n url = 'https://some-fortify-host/ssc'\n user = 'Fortify SSC User'\n password = 'Fortify SSC Password'\n description = 'fortifyapi test client'\n \n # Authenticate and retrieve token\n def token():\n api = FortifyApi(host=url, username=user, password=password, verify_ssl=False)\n response = api.get_token(description=description)\n return response.data['data']['token']\n \n # Re-use token in all requests\n def api():\n api = FortifyApi(host=url, token=token(), verify_ssl=False)\n return api\n \n # List ID, Project/application Version\n def list():\n response = api().get_all_project_versions()\n data = response.data['data']\n for version in data:\n print(\"{0:8} {1:30} {2:30}\".format(version['id'], version['project']['name'], version['name']).encode(\n 'utf-8', errors='ignore').decode())\n \n if __name__ == '__main__':\n list()\n\nBugs and Feature Requests\n~~~~~~~~~~~~~~~~~~~~~~~~~\n\nFound something that doesn't seem right or have a feature request? Please open a new issue.\n\nCopyright and License\n~~~~~~~~~~~~~~~~~~~~~\n.. image:: https://img.shields.io/github/license/fortifyadmin/fortifyapi.svg?style=flat-square\n\n",
"bugtrack_url": null,
"license": "MIT",
"summary": "Python library for Fortify Software Security Center (SSC) RESTFul API",
"version": "3.1.20",
"project_urls": {
"Download": "https://github.com/fortifyadmin/fortifyapi/tarball/3.1.20",
"Homepage": "https://github.com/fortifyadmin/fortifyapi"
},
"split_keywords": [
"fortify",
" api",
" security",
" software",
" microfocus",
" ssc",
" sast"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "64ec08583f6b968a47beb687fb47f36590446d7ab5eba7874098cbcd78081de9",
"md5": "dd3f5b73ecb6ff2585c22bb8857f0408",
"sha256": "a266e7e3c81b8eeb1b54bd79d970584098822b2e22f44b2069d4a82798e55e17"
},
"downloads": -1,
"filename": "fortifyapi-3.1.20-py3-none-any.whl",
"has_sig": false,
"md5_digest": "dd3f5b73ecb6ff2585c22bb8857f0408",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": null,
"size": 23525,
"upload_time": "2024-12-09T15:25:54",
"upload_time_iso_8601": "2024-12-09T15:25:54.979483Z",
"url": "https://files.pythonhosted.org/packages/64/ec/08583f6b968a47beb687fb47f36590446d7ab5eba7874098cbcd78081de9/fortifyapi-3.1.20-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "1923ccafecba7d0ba74890b21ab0fe503f87a87c12040f2cbe48c77ac4ed60b9",
"md5": "ea67197c8537cbbe61408c1af2b3e6c6",
"sha256": "8740dfc4162759c8ea2124d9283fd976c8ca50756404440415825651d5272927"
},
"downloads": -1,
"filename": "fortifyapi-3.1.20.tar.gz",
"has_sig": false,
"md5_digest": "ea67197c8537cbbe61408c1af2b3e6c6",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 29765,
"upload_time": "2024-12-09T15:25:56",
"upload_time_iso_8601": "2024-12-09T15:25:56.185222Z",
"url": "https://files.pythonhosted.org/packages/19/23/ccafecba7d0ba74890b21ab0fe503f87a87c12040f2cbe48c77ac4ed60b9/fortifyapi-3.1.20.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-12-09 15:25:56",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "fortifyadmin",
"github_project": "fortifyapi",
"travis_ci": false,
"coveralls": false,
"github_actions": false,
"circle": true,
"requirements": [
{
"name": "requests",
"specs": []
},
{
"name": "requests-toolbelt",
"specs": []
}
],
"lcname": "fortifyapi"
}