diff --git a/.idea/.gitignore b/.idea/.gitignore new file mode 100644 index 0000000000000000000000000000000000000000..26d33521af10bcc7fd8cea344038eaaeb78d0ef5 --- /dev/null +++ b/.idea/.gitignore @@ -0,0 +1,3 @@ +# Default ignored files +/shelf/ +/workspace.xml diff --git a/.idea/inspectionProfiles/Project_Default.xml b/.idea/inspectionProfiles/Project_Default.xml new file mode 100644 index 0000000000000000000000000000000000000000..83965a1489c45733b94f8b868789eb8452261068 --- /dev/null +++ b/.idea/inspectionProfiles/Project_Default.xml @@ -0,0 +1,41 @@ +<component name="InspectionProjectProfileManager"> + <profile version="1.0"> + <option name="myName" value="Project Default" /> + <inspection_tool class="PyPackageRequirementsInspection" enabled="true" level="WARNING" enabled_by_default="true"> + <option name="ignoredPackages"> + <value> + <list size="21"> + <item index="0" class="java.lang.String" itemvalue="pydantic" /> + <item index="1" class="java.lang.String" itemvalue="networkx" /> + <item index="2" class="java.lang.String" itemvalue="Werkzeug" /> + <item index="3" class="java.lang.String" itemvalue="MarkupSafe" /> + <item index="4" class="java.lang.String" itemvalue="requests" /> + <item index="5" class="java.lang.String" itemvalue="click" /> + <item index="6" class="java.lang.String" itemvalue="importlib-metadata" /> + <item index="7" class="java.lang.String" itemvalue="Jinja2" /> + <item index="8" class="java.lang.String" itemvalue="pyrsistent" /> + <item index="9" class="java.lang.String" itemvalue="importlib-resources" /> + <item index="10" class="java.lang.String" itemvalue="openmetadata-ingestion" /> + <item index="11" class="java.lang.String" itemvalue="python-on-whales" /> + <item index="12" class="java.lang.String" itemvalue="pkg_resources" /> + <item index="13" class="java.lang.String" itemvalue="zipp" /> + <item index="14" class="java.lang.String" itemvalue="typing_extensions" /> + <item index="15" class="java.lang.String" itemvalue="cachetools" /> + <item index="16" class="java.lang.String" itemvalue="itsdangerous" /> + <item index="17" class="java.lang.String" itemvalue="jsonschema" /> + <item index="18" class="java.lang.String" itemvalue="Flask" /> + <item index="19" class="java.lang.String" itemvalue="neo4j" /> + <item index="20" class="java.lang.String" itemvalue="pandas" /> + </list> + </value> + </option> + </inspection_tool> + <inspection_tool class="PyPep8NamingInspection" enabled="true" level="WEAK WARNING" enabled_by_default="true"> + <option name="ignoredErrors"> + <list> + <option value="N802" /> + </list> + </option> + </inspection_tool> + </profile> +</component> \ No newline at end of file diff --git a/.idea/inspectionProfiles/profiles_settings.xml b/.idea/inspectionProfiles/profiles_settings.xml new file mode 100644 index 0000000000000000000000000000000000000000..105ce2da2d6447d11dfe32bfb846c3d5b199fc99 --- /dev/null +++ b/.idea/inspectionProfiles/profiles_settings.xml @@ -0,0 +1,6 @@ +<component name="InspectionProjectProfileManager"> + <settings> + <option name="USE_PROJECT_PROFILE" value="false" /> + <version value="1.0" /> + </settings> +</component> \ No newline at end of file diff --git a/.idea/misc.xml b/.idea/misc.xml new file mode 100644 index 0000000000000000000000000000000000000000..55b09d01c049d6b914264b9166589a2beed072ed --- /dev/null +++ b/.idea/misc.xml @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="UTF-8"?> +<project version="4"> + <component name="ProjectRootManager" version="2" project-jdk-name="Python 3.10 (gaiax-selfdescriptor-module) (2)" project-jdk-type="Python SDK" /> +</project> \ No newline at end of file diff --git a/.idea/modules.xml b/.idea/modules.xml new file mode 100644 index 0000000000000000000000000000000000000000..0ccca45ed9fd422b9d09c74486fccb74b97312fd --- /dev/null +++ b/.idea/modules.xml @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="UTF-8"?> +<project version="4"> + <component name="ProjectModuleManager"> + <modules> + <module fileurl="file://$PROJECT_DIR$/.idea/oasees_on_boarding_git.iml" filepath="$PROJECT_DIR$/.idea/oasees_on_boarding_git.iml" /> + </modules> + </component> +</project> \ No newline at end of file diff --git a/.idea/oasees_on_boarding_git.iml b/.idea/oasees_on_boarding_git.iml new file mode 100644 index 0000000000000000000000000000000000000000..d0876a78d06ac03b5d78c8dcdb95570281c6f1d6 --- /dev/null +++ b/.idea/oasees_on_boarding_git.iml @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="UTF-8"?> +<module type="PYTHON_MODULE" version="4"> + <component name="NewModuleRootManager"> + <content url="file://$MODULE_DIR$" /> + <orderEntry type="inheritedJdk" /> + <orderEntry type="sourceFolder" forTests="false" /> + </component> +</module> \ No newline at end of file diff --git a/.idea/vcs.xml b/.idea/vcs.xml new file mode 100644 index 0000000000000000000000000000000000000000..94a25f7f4cb416c083d265558da75d457237d671 --- /dev/null +++ b/.idea/vcs.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="UTF-8"?> +<project version="4"> + <component name="VcsDirectoryMappings"> + <mapping directory="$PROJECT_DIR$" vcs="Git" /> + </component> +</project> \ No newline at end of file diff --git a/API_OASEES/LICENSE b/API_OASEES/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..d6091d6b0f55b46fc77df106ab7cb77d48423388 --- /dev/null +++ b/API_OASEES/LICENSE @@ -0,0 +1,288 @@ +EUROPEAN UNION PUBLIC LICENCE v. 1.2 + EUPL © the European Union 2007, 2016 + +This European Union Public Licence (the ‘EUPL’) applies to the Work (as defined +below) which is provided under the terms of this Licence. Any use of the Work, +other than as authorised under this Licence is prohibited (to the extent such +use is covered by a right of the copyright holder of the Work). + +The Work is provided under the terms of this Licence when the Licensor (as +defined below) has placed the following notice immediately following the +copyright notice for the Work: + + Licensed under the EUPL + +or has expressed by any other means his willingness to license under the EUPL. + +1. Definitions + +In this Licence, the following terms have the following meaning: + +- ‘The Licence’: this Licence. + +- ‘The Original Work’: the work or software distributed or communicated by the + Licensor under this Licence, available as Source Code and also as Executable + Code as the case may be. + +- ‘Derivative Works’: the works or software that could be created by the + Licensee, based upon the Original Work or modifications thereof. This Licence + does not define the extent of modification or dependence on the Original Work + required in order to classify a work as a Derivative Work; this extent is + determined by copyright law applicable in the country mentioned in Article 15. + +- ‘The Work’: the Original Work or its Derivative Works. + +- ‘The Source Code’: the human-readable form of the Work which is the most + convenient for people to study and modify. + +- ‘The Executable Code’: any code which has generally been compiled and which is + meant to be interpreted by a computer as a program. + +- ‘The Licensor’: the natural or legal person that distributes or communicates + the Work under the Licence. + +- ‘Contributor(s)’: any natural or legal person who modifies the Work under the + Licence, or otherwise contributes to the creation of a Derivative Work. + +- ‘The Licensee’ or ‘You’: any natural or legal person who makes any usage of + the Work under the terms of the Licence. + +- ‘Distribution’ or ‘Communication’: any act of selling, giving, lending, + renting, distributing, communicating, transmitting, or otherwise making + available, online or offline, copies of the Work or providing access to its + essential functionalities at the disposal of any other natural or legal + person. + +2. Scope of the rights granted by the Licence + +The Licensor hereby grants You a worldwide, royalty-free, non-exclusive, +sublicensable licence to do the following, for the duration of copyright vested +in the Original Work: + +- use the Work in any circumstance and for all usage, +- reproduce the Work, +- modify the Work, and make Derivative Works based upon the Work, +- communicate to the public, including the right to make available or display + the Work or copies thereof to the public and perform publicly, as the case may + be, the Work, +- distribute the Work or copies thereof, +- lend and rent the Work or copies thereof, +- sublicense rights in the Work or copies thereof. + +Those rights can be exercised on any media, supports and formats, whether now +known or later invented, as far as the applicable law permits so. + +In the countries where moral rights apply, the Licensor waives his right to +exercise his moral right to the extent allowed by law in order to make effective +the licence of the economic rights here above listed. + +The Licensor grants to the Licensee royalty-free, non-exclusive usage rights to +any patents held by the Licensor, to the extent necessary to make use of the +rights granted on the Work under this Licence. + +3. Communication of the Source Code + +The Licensor may provide the Work either in its Source Code form, or as +Executable Code. If the Work is provided as Executable Code, the Licensor +provides in addition a machine-readable copy of the Source Code of the Work +along with each copy of the Work that the Licensor distributes or indicates, in +a notice following the copyright notice attached to the Work, a repository where +the Source Code is easily and freely accessible for as long as the Licensor +continues to distribute or communicate the Work. + +4. Limitations on copyright + +Nothing in this Licence is intended to deprive the Licensee of the benefits from +any exception or limitation to the exclusive rights of the rights owners in the +Work, of the exhaustion of those rights or of other applicable limitations +thereto. + +5. Obligations of the Licensee + +The grant of the rights mentioned above is subject to some restrictions and +obligations imposed on the Licensee. Those obligations are the following: + +Attribution right: The Licensee shall keep intact all copyright, patent or +trademarks notices and all notices that refer to the Licence and to the +disclaimer of warranties. The Licensee must include a copy of such notices and a +copy of the Licence with every copy of the Work he/she distributes or +communicates. The Licensee must cause any Derivative Work to carry prominent +notices stating that the Work has been modified and the date of modification. + +Copyleft clause: If the Licensee distributes or communicates copies of the +Original Works or Derivative Works, this Distribution or Communication will be +done under the terms of this Licence or of a later version of this Licence +unless the Original Work is expressly distributed only under this version of the +Licence — for example by communicating ‘EUPL v. 1.2 only’. The Licensee +(becoming Licensor) cannot offer or impose any additional terms or conditions on +the Work or Derivative Work that alter or restrict the terms of the Licence. + +Compatibility clause: If the Licensee Distributes or Communicates Derivative +Works or copies thereof based upon both the Work and another work licensed under +a Compatible Licence, this Distribution or Communication can be done under the +terms of this Compatible Licence. For the sake of this clause, ‘Compatible +Licence’ refers to the licences listed in the appendix attached to this Licence. +Should the Licensee's obligations under the Compatible Licence conflict with +his/her obligations under this Licence, the obligations of the Compatible +Licence shall prevail. + +Provision of Source Code: When distributing or communicating copies of the Work, +the Licensee will provide a machine-readable copy of the Source Code or indicate +a repository where this Source will be easily and freely available for as long +as the Licensee continues to distribute or communicate the Work. + +Legal Protection: This Licence does not grant permission to use the trade names, +trademarks, service marks, or names of the Licensor, except as required for +reasonable and customary use in describing the origin of the Work and +reproducing the content of the copyright notice. + +6. Chain of Authorship + +The original Licensor warrants that the copyright in the Original Work granted +hereunder is owned by him/her or licensed to him/her and that he/she has the +power and authority to grant the Licence. + +Each Contributor warrants that the copyright in the modifications he/she brings +to the Work are owned by him/her or licensed to him/her and that he/she has the +power and authority to grant the Licence. + +Each time You accept the Licence, the original Licensor and subsequent +Contributors grant You a licence to their contributions to the Work, under the +terms of this Licence. + +7. Disclaimer of Warranty + +The Work is a work in progress, which is continuously improved by numerous +Contributors. It is not a finished work and may therefore contain defects or +‘bugs’ inherent to this type of development. + +For the above reason, the Work is provided under the Licence on an ‘as is’ basis +and without warranties of any kind concerning the Work, including without +limitation merchantability, fitness for a particular purpose, absence of defects +or errors, accuracy, non-infringement of intellectual property rights other than +copyright as stated in Article 6 of this Licence. + +This disclaimer of warranty is an essential part of the Licence and a condition +for the grant of any rights to the Work. + +8. Disclaimer of Liability + +Except in the cases of wilful misconduct or damages directly caused to natural +persons, the Licensor will in no event be liable for any direct or indirect, +material or moral, damages of any kind, arising out of the Licence or of the use +of the Work, including without limitation, damages for loss of goodwill, work +stoppage, computer failure or malfunction, loss of data or any commercial +damage, even if the Licensor has been advised of the possibility of such damage. +However, the Licensor will be liable under statutory product liability laws as +far such laws apply to the Work. + +9. Additional agreements + +While distributing the Work, You may choose to conclude an additional agreement, +defining obligations or services consistent with this Licence. However, if +accepting obligations, You may act only on your own behalf and on your sole +responsibility, not on behalf of the original Licensor or any other Contributor, +and only if You agree to indemnify, defend, and hold each Contributor harmless +for any liability incurred by, or claims asserted against such Contributor by +the fact You have accepted any warranty or additional liability. + +10. Acceptance of the Licence + +The provisions of this Licence can be accepted by clicking on an icon ‘I agree’ +placed under the bottom of a window displaying the text of this Licence or by +affirming consent in any other similar way, in accordance with the rules of +applicable law. Clicking on that icon indicates your clear and irrevocable +acceptance of this Licence and all of its terms and conditions. + +Similarly, you irrevocably accept this Licence and all of its terms and +conditions by exercising any rights granted to You by Article 2 of this Licence, +such as the use of the Work, the creation by You of a Derivative Work or the +Distribution or Communication by You of the Work or copies thereof. + +11. Information to the public + +In case of any Distribution or Communication of the Work by means of electronic +communication by You (for example, by offering to download the Work from a +remote location) the distribution channel or media (for example, a website) must +at least provide to the public the information requested by the applicable law +regarding the Licensor, the Licence and the way it may be accessible, concluded, +stored and reproduced by the Licensee. + +12. Termination of the Licence + +The Licence and the rights granted hereunder will terminate automatically upon +any breach by the Licensee of the terms of the Licence. + +Such a termination will not terminate the licences of any person who has +received the Work from the Licensee under the Licence, provided such persons +remain in full compliance with the Licence. + +13. Miscellaneous + +Without prejudice of Article 9 above, the Licence represents the complete +agreement between the Parties as to the Work. + +If any provision of the Licence is invalid or unenforceable under applicable +law, this will not affect the validity or enforceability of the Licence as a +whole. Such provision will be construed or reformed so as necessary to make it +valid and enforceable. + +The European Commission may publish other linguistic versions or new versions of +this Licence or updated versions of the Appendix, so far this is required and +reasonable, without reducing the scope of the rights granted by the Licence. New +versions of the Licence will be published with a unique version number. + +All linguistic versions of this Licence, approved by the European Commission, +have identical value. Parties can take advantage of the linguistic version of +their choice. + +14. Jurisdiction + +Without prejudice to specific agreement between parties, + +- any litigation resulting from the interpretation of this License, arising + between the European Union institutions, bodies, offices or agencies, as a + Licensor, and any Licensee, will be subject to the jurisdiction of the Court + of Justice of the European Union, as laid down in article 272 of the Treaty on + the Functioning of the European Union, + +- any litigation arising between other parties and resulting from the + interpretation of this License, will be subject to the exclusive jurisdiction + of the competent court where the Licensor resides or conducts its primary + business. + +15. Applicable Law + +Without prejudice to specific agreement between parties, + +- this Licence shall be governed by the law of the European Union Member State + where the Licensor has his seat, resides or has his registered office, + +- this licence shall be governed by Belgian law if the Licensor has no seat, + residence or registered office inside a European Union Member State. + +Appendix + +‘Compatible Licences’ according to Article 5 EUPL are: + +- GNU General Public License (GPL) v. 2, v. 3 +- GNU Affero General Public License (AGPL) v. 3 +- Open Software License (OSL) v. 2.1, v. 3.0 +- Eclipse Public License (EPL) v. 1.0 +- CeCILL v. 2.0, v. 2.1 +- Mozilla Public Licence (MPL) v. 2 +- GNU Lesser General Public Licence (LGPL) v. 2.1, v. 3 +- Creative Commons Attribution-ShareAlike v. 3.0 Unported (CC BY-SA 3.0) for + works other than software +- European Union Public Licence (EUPL) v. 1.1, v. 1.2 +- Québec Free and Open-Source Licence — Reciprocity (LiLiQ-R) or Strong + Reciprocity (LiLiQ-R+). + +The European Commission may update this Appendix to later versions of the above +licences without producing a new version of the EUPL, as long as they provide +the rights granted in Article 2 of this Licence and protect the covered Source +Code from exclusive appropriation. + +All other changes or additions to this Appendix require the production of a new +EUPL version. + diff --git a/API_OASEES/README.md b/API_OASEES/README.md new file mode 100644 index 0000000000000000000000000000000000000000..2a7074a954c559a13a696d94335d005c837fc07e --- /dev/null +++ b/API_OASEES/README.md @@ -0,0 +1,2 @@ +# gaia-x-self-descriptor module + diff --git a/API_OASEES/app/__init__.py b/API_OASEES/app/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/API_OASEES/app/main.py b/API_OASEES/app/main.py new file mode 100644 index 0000000000000000000000000000000000000000..692d61fdb982583c2c5b76ca3c102aa692ee4c56 --- /dev/null +++ b/API_OASEES/app/main.py @@ -0,0 +1,247 @@ +import logging +import os +import sys +import uvicorn +from datamite.models.dataProductResourcesBody import DataProductResourcesModel +from datamite.models.legalParticipantBodyModel import LegalParticipantBodyModel +from datamite.utils.certificate_utils import sign_doc, signVeriablePresentation +from datamite.utils.gaiax_utils import callCredentialsEventService, callComplianceAPI +from datamite.utils.neo4j_utils import loadInNeo4j, getData_productsList, getData_productsByName +from datamite.utils.postgres_utils import getCesData +from datamite.utils.selfDescription_utils import createDidDocument, \ + createLegalParticipantVerifiablePresentation, \ + createDataProductWithResourcesVerifiablePresentation, \ + createAndPublishDataProductWithResourcesVerifiablePresentation +from fastapi import FastAPI + +from app.utils.connector_utils import load_asset_edc +from contextlib import asynccontextmanager +#from app.utils.connector_utils import load_asset_edc + +tags_metadata = [ + { + "name": "Oasees API" + }, + { + "name": "Oasees testing API" + }, +] + +logger = logging.getLogger("uvicorn.error") + +DEBUG = os.getenv("DEBUG") or False + + + +@asynccontextmanager +async def lifespan(app: FastAPI): + logger = logging.getLogger("uvicorn.error") + handler = logging.StreamHandler() + handler.setFormatter(logging.Formatter("%(asctime)s | %(levelname)s | %(module)s | %(funcName)s | %(message)s")) + logger.addHandler(handler) + logging_level = logging.INFO + if DEBUG: + logging_level = logging.DEBUG + logger.setLevel(logging_level) + logger.propagate = False + yield + + + + + + +app = FastAPI(lifespan=lifespan,title="Oasees", description=f"Oasees API documentation", openapi_tags=tags_metadata) + + +####################################################################### +# Create a did.json file +#Input: domain and certificate_URL: compplete chain for the certifcate +#Output: json document for the did +####################################################################### +@app.post("/diddocument", tags=["Oasees API"]) + +async def create_did(domain: str): + + return createDidDocument(domain) + + + + + +####################################################################### +# Create a Gaia-X Legal Participant +#Input: mandatory input data +#Output: JSON for LegalParticipant signed/unsigned +####################################################################### + + +@app.post("/legalparticipant", tags=["Oasees API"]) + + +async def createLegalParticipant(body:LegalParticipantBodyModel): + + return createLegalParticipantVerifiablePresentation (body) + + +####################################################################### +# Create a definition for a DataProduct/Service Offering +#Input: mandatory input data +#Output: JSON for DataProduct/Service signed/unsigned +####################################################################### +""" +@app.post("/createDataProduct", tags=["Datamite External API"]) +async def createDataProduct(body:DataProductBodyModel): + + return createDataProductVeriableCredential(body) +""" + +####################################################################### +# Create a definition for a DataProduct/Service Offering with resources DataResources +#Input: mandatory input data +#Output: JSON for DataProduct/Service Offering with DataResources +####################################################################### + +@app.post("/dataproduct", tags=["Oasees API"]) + +async def createDataProductWithResources(body:DataProductResourcesModel): + + return createDataProductWithResourcesVerifiablePresentation(body) + + + + + +####################################################################### +# Create a definition for a DataProduct/Service Offering with resources DataResources +#Input: mandatory input data +#Output: JSON for DataProduct/Service Offering with DataResources +####################################################################### +@app.post("/publish-dataproduct", tags=["Oasees API"]) + +async def createAndPublishDataProduct(body:DataProductResourcesModel, dataResouceAPI_URL:str): + + + output=createAndPublishDataProductWithResourcesVerifiablePresentation(body) + print("Output create and publish data product with resources") + print (output) + #output="CES" + outputEDC = load_asset_edc(body, dataResouceAPI_URL) + print (outputEDC) + if "CES" in output and outputEDC: + return output + + + + + +####################################################################### +# Method for getting dataProducts from Neo4j + +#Output: list of dataProducts +####################################################################### +@app.get("/dataproducts", tags=["Oasees API"]) + +async def getDataProductsList(): + + return getData_productsList() + + + +####################################################################### +# Method for getting dataProducts by name from Neo4j + +#Output: dataProduct Name +####################################################################### +@app.get("/dataproduct", tags=["Oasees API"]) + +async def getDataProductByName(dataProductName:str): + + return getData_productsByName(dataProductName) + +####################################################################### +# Method for getting CesRecords + +#Output: cesProducts +####################################################################### +@app.get("/cesrecords", tags=["Oasees API"]) + +async def getCesRecords(): + + return getCesData() + + + +####################################################################### +# Sign a verifiable credential +#Input: data for being signed and domain +#Output: data signed +####################################################################### +@app.post("/signVC", tags=["Oasees testing API"]) + + +async def signVC(data: dict , issuerKey:str): + + return sign_doc(data,issuerKey) + + +####################################################################### +# Sign a verifiable presentation +#Input: data for being signed and domain +#Output: data signed +####################################################################### +@app.post("/sign-vp", tags=["Oasees testing API"]) + +async def signVP(data: dict , domain:str): + + + return signVeriablePresentation(data,domain) + + + + +####################################################################### +# Method for calling to Gaia-X Compliance Service +#Input: a Veriable Presentation in json format +#Output: Compliance service output +####################################################################### + + +@app.post("/compliance", tags=["Oasees testing API"]) +async def callToCompliance(body: dict): + + return callComplianceAPI(body) + + + + +####################################################################### +# Method for calling to Credential Event Service and registers serviceOffering +#Input: a compliance Veriable Presentation for Service Offering +#Output: Credential Event Service output +####################################################################### +@app.post("/credential-event-service", tags=["Oasees testing API"]) +async def callToCredentialsEventService(body: dict): + + return callCredentialsEventService(body) + + + +####################################################################### +# Method for testing Neo4j +#Input: a compacted json file +#Output: json loaded in neo4j graph database +####################################################################### +@app.post("/loadNeo4j", tags=["Oasees testing API"]) + +async def loadNeo4j(dataProductName:str,data:dict): + + return loadInNeo4j(dataProductName,data) + + + + +if __name__ == "__main__": + uvicorn.run(app, host="0.0.0.0", port=9102) + + diff --git a/API_OASEES/app/utils/__init__.py b/API_OASEES/app/utils/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/API_OASEES/app/utils/connector_utils.py b/API_OASEES/app/utils/connector_utils.py new file mode 100644 index 0000000000000000000000000000000000000000..09530a3c6f532a1c6e0317da4603050e316ebd01 --- /dev/null +++ b/API_OASEES/app/utils/connector_utils.py @@ -0,0 +1,45 @@ +import json +import os + +from datamite.models.dataProductResourcesBody import DataProductResourcesModel +from fastapi import HTTPException + +from app.utils.create_asset import invoke_create_asset +from app.utils.create_policy import invoke_create_policy, checkPolicyId +from app.utils.create_contract_definition import invoke_create_contract_definition + +def load_asset_edc(body:DataProductResourcesModel, dataResouceAPi_URL:str): + + header_authorization = os.getenv("HEADER_AUTHORIZATION") + + # asset_id = asset_id.replace(os.getenv("DOMAIN_PART"),"") + # Create asset + for dataresource in body.dataResources: + formatType = body.dataAccount[0].formatType + if dataresource.dataResourceInfo is not None: + create_asset_response = invoke_create_asset(dataresource.dataResourceInfo.name, body.dataProductName, + formatType, dataresource.dataResourceInfo.description, + dataResouceAPi_URL, + header_authorization) + if not create_asset_response.ok: + raise HTTPException(status_code=400, detail=json.loads(create_asset_response.text)) + + # Create policy + policy_id = os.getenv("POLICY_ID") + contract_id = os.getenv("CONTRACT_ID") + policyExist = checkPolicyId(policy_id, header_authorization) + if not policyExist: + create_policy_response = invoke_create_policy(policy_id, header_authorization) + print (json.loads(create_policy_response.text)) + + + + create_contract_response = invoke_create_contract_definition(contract_id, policy_id, + dataresource.dataResourceInfo.name, + header_authorization) + + print(json.loads(create_contract_response.text)) + + + print (f'Asset {body.dataProductName} created') + return True diff --git a/API_OASEES/app/utils/create_asset.py b/API_OASEES/app/utils/create_asset.py new file mode 100644 index 0000000000000000000000000000000000000000..d99a3905a43b01aee9342a5ba04c808ec243d202 --- /dev/null +++ b/API_OASEES/app/utils/create_asset.py @@ -0,0 +1,50 @@ +import os +import json +import requests + + +def invoke_create_asset(dataProductId:str,dataProductName:str, dataProductFormatType:str,dataProductDescription:str,openAPI:str,header_authorization:str): + provider_host = os.getenv("PROVIDER_HOST") + provider_management_port = os.getenv("PROVIDER_MANAGEMENT_PORT") + + url = f"http://{provider_host}:{provider_management_port}/management/v3/assets" + + payload = json.dumps(generate_asset_metadata(dataProductId,dataProductName,dataProductFormatType,dataProductDescription,openAPI)) + """headers = { + 'Content-Type': 'application/json', + 'X-API-Key': header_authorization + }""" + headers = { + 'Content-Type': 'application/json' + + } + response = requests.request("POST", url, headers=headers, data=payload) + + print(f"Create asset response={response.text}") + + return response + + +def generate_asset_metadata(assetId:str,dataProductName:str,dataProductFormatType:str, dataProductDescription:str,openAPI:str): + asset_metadata = { + "@context": { + "edc": "https://w3id.org/edc/v0.0.1/ns/", + "dqv": "http://www.w3.org/ns/dqv#" + }, + "@id": assetId, + "properties": { + "name": dataProductName, + "contenttype": dataProductFormatType, + }, + "dataAddress": { + "type": "HttpData", + "name": dataProductDescription, + "baseUrl": openAPI, + "proxyQueryParams": "true", + "proxyPath": "true", + "proxyMethod": "true", + "proxyBody": "true" + } + } + + return asset_metadata diff --git a/API_OASEES/app/utils/create_contract_definition.py b/API_OASEES/app/utils/create_contract_definition.py new file mode 100644 index 0000000000000000000000000000000000000000..d431ed2fb09d854c435efd9ca090a0b1a39ccc0e --- /dev/null +++ b/API_OASEES/app/utils/create_contract_definition.py @@ -0,0 +1,82 @@ +import os +import json +import requests + + + + + +def invoke_create_contract_definition(contract_id, policy_id, asset_id,header_authorization): + provider_host = os.getenv("PROVIDER_HOST", "ekodata2.tri.lan") + provider_management_port = os.getenv("PROVIDER_MANAGEMENT_PORT", "9193") + + url = f"http://{provider_host}:{provider_management_port}/management/v2/contractdefinitions" + + payload = json.dumps(generate_contract_metadata(contract_id, policy_id, asset_id)) + """headers = { + 'Content-Type': 'application/json', + 'X-API-Key': header_authorization + }""" + headers = { + 'Content-Type': 'application/json' + } + + response = requests.request("POST", url, headers=headers, data=payload) + + print(f"Negotiate contract response={response.text}") + return response + + +def invoke_create_contract_definition_equal(contract_id, policy_id, asset_id): + provider_host = os.getenv("PROVIDER_HOST", "ekodata2.tri.lan") + provider_management_port = os.getenv("PROVIDER_MANAGEMENT_PORT", "9193") + + url = f"http://{provider_host}:{provider_management_port}/management/v2/contractdefinitions" + + payload = json.dumps(generate_contract_metadata_equal(contract_id, policy_id, asset_id)) + headers = { + 'Content-Type': 'application/json' + } + + response = requests.request("POST", url, headers=headers, data=payload) + + print(f"Negotiate contract response={response.text}") + return response + + + + +def generate_contract_metadata(contract_id, policy_id, asset_id): + contract_metadata = { + "@context": { + "edc": "https://w3id.org/edc/v0.0.1/ns/" + }, + "@id": contract_id, + "accessPolicyId": policy_id, + "contractPolicyId": policy_id, + "assetsSelector": { + "@type": "edc:Criterion", + "edc:operandLeft": "https://w3id.org/edc/v0.0.1/ns/id", + "edc:operator": "in", + "edc:operandRight": asset_id + } + } + return contract_metadata + + +def generate_contract_metadata_equal(contract_id, policy_id, asset_id): + contract_metadata = { + "@context": { + "edc": "https://w3id.org/edc/v0.0.1/ns/" + }, + "@id": contract_id, + "accessPolicyId": policy_id, + "contractPolicyId": policy_id, + "assetsSelector": { + "@type": "edc:Criterion", + "edc:operandLeft": "https://w3id.org/edc/v0.0.1/ns/id", + "edc:operator": "=", + "edc:operandRight": asset_id + } + } + return contract_metadata \ No newline at end of file diff --git a/API_OASEES/app/utils/create_policy.py b/API_OASEES/app/utils/create_policy.py new file mode 100644 index 0000000000000000000000000000000000000000..029c4215f6b00711dcdeb43a6d01a0223359d61d --- /dev/null +++ b/API_OASEES/app/utils/create_policy.py @@ -0,0 +1,150 @@ +import json +import os +import requests + +def checkPolicyId(policy_id,header_authorization): + provider_host = os.getenv("PROVIDER_HOST") + provider_management_port = os.getenv("PROVIDER_MANAGEMENT_PORT") + + url = f"http://{provider_host}:{provider_management_port}/management/v2/policydefinitions/request" + + + """headers = { + 'Content-Type': 'application/json', + 'X-API-Key': header_authorization + }""" + headers = { + 'Content-Type': 'application/json' + } + response = requests.request("POST", url, headers=headers) + response_json=json.loads(response.text) + for policy in response_json: + + print (policy.get("@id")) + if (policy.get("@id") == policy_id): + return True + break + + + + + +def invoke_create_policy(policy_id,header_authorization): + provider_host = os.getenv("PROVIDER_HOST", "ekodata2.tri.lan") + provider_management_port = os.getenv("PROVIDER_MANAGEMENT_PORT", "9193") + + url = f"http://{provider_host}:{provider_management_port}/management/v2/policydefinitions" + + payload = json.dumps(generate_policy_metadata_without_restrictions(policy_id)) + """headers = { + 'Content-Type': 'application/json', + 'X-API-Key': header_authorization + }""" + headers = { + 'Content-Type': 'application/json' + } + response = requests.request("POST", url, headers=headers, data=payload) + + print(f"Create policy response={response.text}") + return response + +def invoke_create_policy_time(policy_id, policy_time_interval, policy_time_interval_start_date, + policy_time_interval_end_date): + provider_host = os.getenv("PROVIDER_HOST", "ekodata2.tri.lan") + provider_management_port = os.getenv("PROVIDER_MANAGEMENT_PORT", "9193") + + url = f"http://{provider_host}:{provider_management_port}/management/v2/policydefinitions" + + payload = json.dumps(generate_policy_metadata_time(policy_id, policy_time_interval, policy_time_interval_start_date, + policy_time_interval_end_date)) + headers = { + 'Content-Type': 'application/json' + } + + response = requests.request("POST", url, headers=headers, data=payload) + + print(f"Create policy response={response.text}") + return response + +def generate_policy_metadata_time(policy_id, policy_time_interval, policy_time_interval_start_date, + policy_time_interval_end_date): + policy_metadata = { + "@context": { + "@vocab" : "https://w3id.org/edc/v0.0.1/ns/" + }, + "@id": policy_id, + "@type": "edc:PolicyDefinition", + "policy": { + "@context": "http://www.w3.org/ns/odrl.jsonld", + "@type": "Set", + "permission": [], + "prohibition": [], + "obligation": [] + } + } + if (policy_time_interval == "true") and (len(policy_time_interval_start_date) > 0) and (len(policy_time_interval_end_date) > 0): + permission_metadata = [ + { + "action": "use", + "constraint": [ + { + "@type": "AtomicConstraint", + "leftOperand": "https://w3id.org/edc/v0.0.1/ns/timeInterval", + "rightOperand": { + "@type": "xsd:date", + "@value": policy_time_interval_start_date + }, + "operator": { + "@id":"odrl:gteq" + } + }, + { + "@type": "AtomicConstraint", + "odrl:leftOperand": "https://w3id.org/edc/v0.0.1/ns/timeInterval", + "rightOperand": { + "@type": "xsd:date", + "@value": policy_time_interval_end_date + }, + "operator": { + "@id": "odrl:lteq" + } + } + ] + } + ] + policy_metadata["policy"]["permission"].append(permission_metadata) + + return policy_metadata + +def generate_policy_metadata_without_restrictions(policy_id): + policy_metadata = { + "@context": { + "@vocab" : "https://w3id.org/edc/v0.0.1/ns/" + }, + "@id": policy_id, + "@type": "edc:PolicyDefinition", + "policy": { + "@context": "http://www.w3.org/ns/odrl.jsonld", + "@type": "Set", + "permission": [], + "prohibition": [], + "obligation": [] + } + } + #edc 0.3.1 + policy_metadata = { + "@context": { + "edc": "https://w3id.org/edc/v0.0.1/ns/", + "odrl": "http://www.w3.org/ns/odrl/2/" + }, + "@id": policy_id, + "@type": "edc:PolicyDefinition", + "edc:policy": { + "@type": "odrl:Set", + "odrl:permission": [], + "odrl:prohibition": [], + "odrl:obligation": [] + } + } + + return policy_metadata diff --git a/API_OASEES/datamite-1.0-py2.py3-none-any.whl b/API_OASEES/datamite-1.0-py2.py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..b943f85a9f06fc30c6815cbd47bdad8ea5ff232c Binary files /dev/null and b/API_OASEES/datamite-1.0-py2.py3-none-any.whl differ diff --git a/API_OASEES/local_wheels/PyJWT-2.8.0-py3-none-any.whl b/API_OASEES/local_wheels/PyJWT-2.8.0-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..8d3635002b36bf9551f6302cc9fc6a09a4faba5c Binary files /dev/null and b/API_OASEES/local_wheels/PyJWT-2.8.0-py3-none-any.whl differ diff --git a/API_OASEES/local_wheels/PyLD-2.0.4-py3-none-any.whl b/API_OASEES/local_wheels/PyLD-2.0.4-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..67b5edfc66d077e70b8766a2276344346ce4ee92 Binary files /dev/null and b/API_OASEES/local_wheels/PyLD-2.0.4-py3-none-any.whl differ diff --git a/API_OASEES/local_wheels/annotated_types-0.6.0-py3-none-any.whl b/API_OASEES/local_wheels/annotated_types-0.6.0-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..acb80e7d58c4052a81f7b9a373662c8b20ad662f Binary files /dev/null and b/API_OASEES/local_wheels/annotated_types-0.6.0-py3-none-any.whl differ diff --git a/API_OASEES/local_wheels/anyio-4.3.0-py3-none-any.whl b/API_OASEES/local_wheels/anyio-4.3.0-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..3e95a11d45107f120f4489cca88aac49802d9a96 Binary files /dev/null and b/API_OASEES/local_wheels/anyio-4.3.0-py3-none-any.whl differ diff --git a/API_OASEES/local_wheels/cachetools-5.3.3-py3-none-any.whl b/API_OASEES/local_wheels/cachetools-5.3.3-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..c0676942fe430d045156850d14ca1c294550d9f7 Binary files /dev/null and b/API_OASEES/local_wheels/cachetools-5.3.3-py3-none-any.whl differ diff --git a/API_OASEES/local_wheels/certifi-2024.2.2-py3-none-any.whl b/API_OASEES/local_wheels/certifi-2024.2.2-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..450e3bd709d1da5a7c7f89e1cbb7b7e5841a6992 Binary files /dev/null and b/API_OASEES/local_wheels/certifi-2024.2.2-py3-none-any.whl differ diff --git a/API_OASEES/local_wheels/cffi-1.16.0-cp310-cp310-win_amd64.whl b/API_OASEES/local_wheels/cffi-1.16.0-cp310-cp310-win_amd64.whl new file mode 100644 index 0000000000000000000000000000000000000000..e1e9c27184fc26c5711819a7637f9cf934b42e23 Binary files /dev/null and b/API_OASEES/local_wheels/cffi-1.16.0-cp310-cp310-win_amd64.whl differ diff --git a/API_OASEES/local_wheels/charset_normalizer-3.3.2-cp310-cp310-win_amd64.whl b/API_OASEES/local_wheels/charset_normalizer-3.3.2-cp310-cp310-win_amd64.whl new file mode 100644 index 0000000000000000000000000000000000000000..8362ebcf5169a5eb66ef371310d7e36ce390f1cc Binary files /dev/null and b/API_OASEES/local_wheels/charset_normalizer-3.3.2-cp310-cp310-win_amd64.whl differ diff --git a/API_OASEES/local_wheels/click-8.1.7-py3-none-any.whl b/API_OASEES/local_wheels/click-8.1.7-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..5e8a550d5bfd9bfbd8be80395361d54318f10764 Binary files /dev/null and b/API_OASEES/local_wheels/click-8.1.7-py3-none-any.whl differ diff --git a/API_OASEES/local_wheels/colorama-0.4.6-py2.py3-none-any.whl b/API_OASEES/local_wheels/colorama-0.4.6-py2.py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..f666ce989f84a46703ead9fa296a74c24e60b590 Binary files /dev/null and b/API_OASEES/local_wheels/colorama-0.4.6-py2.py3-none-any.whl differ diff --git a/API_OASEES/local_wheels/cryptography-42.0.5-cp39-abi3-win_amd64.whl b/API_OASEES/local_wheels/cryptography-42.0.5-cp39-abi3-win_amd64.whl new file mode 100644 index 0000000000000000000000000000000000000000..6654b17e45e5e450f48a485f57c0c1bf16197d2f Binary files /dev/null and b/API_OASEES/local_wheels/cryptography-42.0.5-cp39-abi3-win_amd64.whl differ diff --git a/API_OASEES/local_wheels/cryptography-42.0.6-cp39-abi3-win_amd64.whl b/API_OASEES/local_wheels/cryptography-42.0.6-cp39-abi3-win_amd64.whl new file mode 100644 index 0000000000000000000000000000000000000000..bdb9cf56c55a35b5f9bb5ff740428e75550aa63e Binary files /dev/null and b/API_OASEES/local_wheels/cryptography-42.0.6-cp39-abi3-win_amd64.whl differ diff --git a/API_OASEES/local_wheels/cryptography-42.0.7-cp39-abi3-win_amd64.whl b/API_OASEES/local_wheels/cryptography-42.0.7-cp39-abi3-win_amd64.whl new file mode 100644 index 0000000000000000000000000000000000000000..19c0fa8b6eaa876084e3367476ca3e25c4888e57 Binary files /dev/null and b/API_OASEES/local_wheels/cryptography-42.0.7-cp39-abi3-win_amd64.whl differ diff --git a/API_OASEES/local_wheels/datamite-1.8-py2.py3-none-any.whl b/API_OASEES/local_wheels/datamite-1.8-py2.py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..7e8916d563ed7ca5a5d025651116c4d64c162dcd Binary files /dev/null and b/API_OASEES/local_wheels/datamite-1.8-py2.py3-none-any.whl differ diff --git a/API_OASEES/local_wheels/exceptiongroup-1.2.0-py3-none-any.whl b/API_OASEES/local_wheels/exceptiongroup-1.2.0-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..9195d365ff67b00d70ac2f40d375600049a32c00 Binary files /dev/null and b/API_OASEES/local_wheels/exceptiongroup-1.2.0-py3-none-any.whl differ diff --git a/API_OASEES/local_wheels/exceptiongroup-1.2.1-py3-none-any.whl b/API_OASEES/local_wheels/exceptiongroup-1.2.1-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..494f2626e8221a08ed97b10c6f15db1ffe1649e3 Binary files /dev/null and b/API_OASEES/local_wheels/exceptiongroup-1.2.1-py3-none-any.whl differ diff --git a/API_OASEES/local_wheels/fastapi-0.109.2-py3-none-any.whl b/API_OASEES/local_wheels/fastapi-0.109.2-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..d63b090557b4b96ee03ef0cb2bd3c9ecb88e63d2 Binary files /dev/null and b/API_OASEES/local_wheels/fastapi-0.109.2-py3-none-any.whl differ diff --git a/API_OASEES/local_wheels/frozendict-2.4.0-cp310-cp310-win_amd64.whl b/API_OASEES/local_wheels/frozendict-2.4.0-cp310-cp310-win_amd64.whl new file mode 100644 index 0000000000000000000000000000000000000000..1f214c2827d30219ddfbffef3d2d126384918a4e Binary files /dev/null and b/API_OASEES/local_wheels/frozendict-2.4.0-cp310-cp310-win_amd64.whl differ diff --git a/API_OASEES/local_wheels/frozendict-2.4.1-cp310-cp310-win_amd64.whl b/API_OASEES/local_wheels/frozendict-2.4.1-cp310-cp310-win_amd64.whl new file mode 100644 index 0000000000000000000000000000000000000000..1e6102045ec57a5d6e16c61ab2d0f63a3fc85212 Binary files /dev/null and b/API_OASEES/local_wheels/frozendict-2.4.1-cp310-cp310-win_amd64.whl differ diff --git a/API_OASEES/local_wheels/frozendict-2.4.3-cp310-cp310-win_amd64.whl b/API_OASEES/local_wheels/frozendict-2.4.3-cp310-cp310-win_amd64.whl new file mode 100644 index 0000000000000000000000000000000000000000..e5471b664af5a684e8cd8efd68b15c78049dca7b Binary files /dev/null and b/API_OASEES/local_wheels/frozendict-2.4.3-cp310-cp310-win_amd64.whl differ diff --git a/API_OASEES/local_wheels/frozendict-2.4.4-cp310-cp310-win_amd64.whl b/API_OASEES/local_wheels/frozendict-2.4.4-cp310-cp310-win_amd64.whl new file mode 100644 index 0000000000000000000000000000000000000000..c11798c3ae7486cb2921728fb142d3e6c29d238f Binary files /dev/null and b/API_OASEES/local_wheels/frozendict-2.4.4-cp310-cp310-win_amd64.whl differ diff --git a/API_OASEES/local_wheels/h11-0.14.0-py3-none-any.whl b/API_OASEES/local_wheels/h11-0.14.0-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..a02c8de7c1c4c5fa7825d707cf79071c1a980df7 Binary files /dev/null and b/API_OASEES/local_wheels/h11-0.14.0-py3-none-any.whl differ diff --git a/API_OASEES/local_wheels/idna-3.6-py3-none-any.whl b/API_OASEES/local_wheels/idna-3.6-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..fdf65ae30cb847fd4742dd28aa5027d9e569f885 Binary files /dev/null and b/API_OASEES/local_wheels/idna-3.6-py3-none-any.whl differ diff --git a/API_OASEES/local_wheels/idna-3.7-py3-none-any.whl b/API_OASEES/local_wheels/idna-3.7-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..fa4c95b123751094438c2f747e5389c32d870c5b Binary files /dev/null and b/API_OASEES/local_wheels/idna-3.7-py3-none-any.whl differ diff --git a/API_OASEES/local_wheels/jwcrypto-1.5.6-py3-none-any.whl b/API_OASEES/local_wheels/jwcrypto-1.5.6-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..e2a712c9296144407618625c97874f96115812cf Binary files /dev/null and b/API_OASEES/local_wheels/jwcrypto-1.5.6-py3-none-any.whl differ diff --git a/API_OASEES/local_wheels/lxml-5.1.0-cp310-cp310-win_amd64.whl b/API_OASEES/local_wheels/lxml-5.1.0-cp310-cp310-win_amd64.whl new file mode 100644 index 0000000000000000000000000000000000000000..844b4ceb5e89ae122ef1e7ad03d7a47102f183a9 Binary files /dev/null and b/API_OASEES/local_wheels/lxml-5.1.0-cp310-cp310-win_amd64.whl differ diff --git a/API_OASEES/local_wheels/lxml-5.2.0-cp310-cp310-win_amd64.whl b/API_OASEES/local_wheels/lxml-5.2.0-cp310-cp310-win_amd64.whl new file mode 100644 index 0000000000000000000000000000000000000000..0db33544e75dd19eccbb8c63ade69174ebe85677 Binary files /dev/null and b/API_OASEES/local_wheels/lxml-5.2.0-cp310-cp310-win_amd64.whl differ diff --git a/API_OASEES/local_wheels/lxml-5.2.1-cp310-cp310-win_amd64.whl b/API_OASEES/local_wheels/lxml-5.2.1-cp310-cp310-win_amd64.whl new file mode 100644 index 0000000000000000000000000000000000000000..489b0e373bb0ad45fcffd2e8e7caed6672f12fb1 Binary files /dev/null and b/API_OASEES/local_wheels/lxml-5.2.1-cp310-cp310-win_amd64.whl differ diff --git a/API_OASEES/local_wheels/lxml-5.2.2-cp310-cp310-win_amd64.whl b/API_OASEES/local_wheels/lxml-5.2.2-cp310-cp310-win_amd64.whl new file mode 100644 index 0000000000000000000000000000000000000000..c88e449ade92b39a076806a7bf8ce9f8e5bb95b3 Binary files /dev/null and b/API_OASEES/local_wheels/lxml-5.2.2-cp310-cp310-win_amd64.whl differ diff --git a/API_OASEES/local_wheels/neo4j-5.13.0-py3-none-any.whl b/API_OASEES/local_wheels/neo4j-5.13.0-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..37b81ba33aba47f8f4726e151ffb12b27e4533d3 Binary files /dev/null and b/API_OASEES/local_wheels/neo4j-5.13.0-py3-none-any.whl differ diff --git a/API_OASEES/local_wheels/numpy-1.26.4-cp310-cp310-win_amd64.whl b/API_OASEES/local_wheels/numpy-1.26.4-cp310-cp310-win_amd64.whl new file mode 100644 index 0000000000000000000000000000000000000000..3886f83b73e94109ffd22f2bad024b5004b26f1c Binary files /dev/null and b/API_OASEES/local_wheels/numpy-1.26.4-cp310-cp310-win_amd64.whl differ diff --git a/API_OASEES/local_wheels/orjson-3.9.15-cp310-none-win_amd64.whl b/API_OASEES/local_wheels/orjson-3.9.15-cp310-none-win_amd64.whl new file mode 100644 index 0000000000000000000000000000000000000000..da9d1605b63f89006c1cdc787810083d4683821d Binary files /dev/null and b/API_OASEES/local_wheels/orjson-3.9.15-cp310-none-win_amd64.whl differ diff --git a/API_OASEES/local_wheels/pandas-2.1.4-cp310-cp310-win_amd64.whl b/API_OASEES/local_wheels/pandas-2.1.4-cp310-cp310-win_amd64.whl new file mode 100644 index 0000000000000000000000000000000000000000..c2929705a2fca323b04df719cb7a10b145d385fb Binary files /dev/null and b/API_OASEES/local_wheels/pandas-2.1.4-cp310-cp310-win_amd64.whl differ diff --git a/API_OASEES/local_wheels/pycparser-2.21-py2.py3-none-any.whl b/API_OASEES/local_wheels/pycparser-2.21-py2.py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..fef6735a27d21820e27aeec8991df1cb1996a3f9 Binary files /dev/null and b/API_OASEES/local_wheels/pycparser-2.21-py2.py3-none-any.whl differ diff --git a/API_OASEES/local_wheels/pycparser-2.22-py3-none-any.whl b/API_OASEES/local_wheels/pycparser-2.22-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..b47818710e16179213829ac49a44467f01e35bb4 Binary files /dev/null and b/API_OASEES/local_wheels/pycparser-2.22-py3-none-any.whl differ diff --git a/API_OASEES/local_wheels/pydantic-2.6.4-py3-none-any.whl b/API_OASEES/local_wheels/pydantic-2.6.4-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..1fae395065b9e865669ce58a447af7818813fbaf Binary files /dev/null and b/API_OASEES/local_wheels/pydantic-2.6.4-py3-none-any.whl differ diff --git a/API_OASEES/local_wheels/pydantic_core-2.16.3-cp310-none-win_amd64.whl b/API_OASEES/local_wheels/pydantic_core-2.16.3-cp310-none-win_amd64.whl new file mode 100644 index 0000000000000000000000000000000000000000..83b2b96c9de00175b348d24b442375f30beba693 Binary files /dev/null and b/API_OASEES/local_wheels/pydantic_core-2.16.3-cp310-none-win_amd64.whl differ diff --git a/API_OASEES/local_wheels/python_dateutil-2.9.0.post0-py2.py3-none-any.whl b/API_OASEES/local_wheels/python_dateutil-2.9.0.post0-py2.py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..b9a14e1bf98404e31ba5398c4d84cbd76dcf8e84 Binary files /dev/null and b/API_OASEES/local_wheels/python_dateutil-2.9.0.post0-py2.py3-none-any.whl differ diff --git a/API_OASEES/local_wheels/pytz-2024.1-py2.py3-none-any.whl b/API_OASEES/local_wheels/pytz-2024.1-py2.py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..571f586a0d36210442b50278b757b07fc37fdbba Binary files /dev/null and b/API_OASEES/local_wheels/pytz-2024.1-py2.py3-none-any.whl differ diff --git a/API_OASEES/local_wheels/requests-2.31.0-py3-none-any.whl b/API_OASEES/local_wheels/requests-2.31.0-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..bfd5d2ea99d7b026e75e9aa393a0cad8f829efb5 Binary files /dev/null and b/API_OASEES/local_wheels/requests-2.31.0-py3-none-any.whl differ diff --git a/API_OASEES/local_wheels/six-1.16.0-py2.py3-none-any.whl b/API_OASEES/local_wheels/six-1.16.0-py2.py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..fd942658a2f748ba433dd8632abb910a416e184f Binary files /dev/null and b/API_OASEES/local_wheels/six-1.16.0-py2.py3-none-any.whl differ diff --git a/API_OASEES/local_wheels/sniffio-1.3.1-py3-none-any.whl b/API_OASEES/local_wheels/sniffio-1.3.1-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..04f44e47d69d33e39c88ce206e3f100443083f17 Binary files /dev/null and b/API_OASEES/local_wheels/sniffio-1.3.1-py3-none-any.whl differ diff --git a/API_OASEES/local_wheels/starlette-0.36.3-py3-none-any.whl b/API_OASEES/local_wheels/starlette-0.36.3-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..318486f92010faf79d0ca20336751cabfbbe193b Binary files /dev/null and b/API_OASEES/local_wheels/starlette-0.36.3-py3-none-any.whl differ diff --git a/API_OASEES/local_wheels/typing_extensions-4.10.0-py3-none-any.whl b/API_OASEES/local_wheels/typing_extensions-4.10.0-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..ce56f2ad9b8548f242bc18b7c172c31c7d99c0db Binary files /dev/null and b/API_OASEES/local_wheels/typing_extensions-4.10.0-py3-none-any.whl differ diff --git a/API_OASEES/local_wheels/typing_extensions-4.11.0-py3-none-any.whl b/API_OASEES/local_wheels/typing_extensions-4.11.0-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..117651413b720616806f443664561004a0302de2 Binary files /dev/null and b/API_OASEES/local_wheels/typing_extensions-4.11.0-py3-none-any.whl differ diff --git a/API_OASEES/local_wheels/tzdata-2024.1-py2.py3-none-any.whl b/API_OASEES/local_wheels/tzdata-2024.1-py2.py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..236fda48d735fd0b3856b387e137bbb10529953b Binary files /dev/null and b/API_OASEES/local_wheels/tzdata-2024.1-py2.py3-none-any.whl differ diff --git a/API_OASEES/local_wheels/urllib3-2.2.1-py3-none-any.whl b/API_OASEES/local_wheels/urllib3-2.2.1-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..d7cca6a473137e22739248c814ef561b2f8fccc4 Binary files /dev/null and b/API_OASEES/local_wheels/urllib3-2.2.1-py3-none-any.whl differ diff --git a/API_OASEES/local_wheels/uvicorn-0.27.1-py3-none-any.whl b/API_OASEES/local_wheels/uvicorn-0.27.1-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..b9589930ee2e4b139b477978b1dae6e7e6b20bfc Binary files /dev/null and b/API_OASEES/local_wheels/uvicorn-0.27.1-py3-none-any.whl differ diff --git a/API_OASEES/local_wheels/validators-0.22.0-py3-none-any.whl b/API_OASEES/local_wheels/validators-0.22.0-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..00cadb1ed1036ab19b0d19ec4bdb625b09cba77b Binary files /dev/null and b/API_OASEES/local_wheels/validators-0.22.0-py3-none-any.whl differ diff --git a/API_OASEES/logging.conf b/API_OASEES/logging.conf new file mode 100644 index 0000000000000000000000000000000000000000..b249532bf9fe092e04ae42d317dda2dc2c60583f --- /dev/null +++ b/API_OASEES/logging.conf @@ -0,0 +1,22 @@ +[loggers] +keys=root + + +[handlers] +keys=consoleHandler + +[formatters] +keys=simpleFormatter + +[logger_root] +level=DEBUG +handlers=consoleHandler + +[handler_consoleHandler] +class=StreamHandler +level=DEBUG +formatter=simpleFormatter +args=(sys.stdout,) + +[formatter_simpleFormatter] +format=%(asctime)s - %(name)s - %(levelname)s - %(message)s \ No newline at end of file diff --git a/API_OASEES/oasees.env b/API_OASEES/oasees.env new file mode 100644 index 0000000000000000000000000000000000000000..1733d5671fcef252093cfb89c3f9edd7576da3fc --- /dev/null +++ b/API_OASEES/oasees.env @@ -0,0 +1,156 @@ +# INFO level: +#LOGGING_LEVEL=20 +# DEBUG level: +LOGGING_LEVEL=10 +DEBUG=True + +DEVELOPMENT=false + +RN_URL_END=lrn.json +TC_URL_END=tsandcs.json +PROTOCOL=https:// +FOLDER=/.well-known/ +PARTICIPANT_END=vc_participant.json +SERVICE_ACCESS_POINT=serviceAccessPoint +DATARESOURCE=dataresource +DATAPRODUCT=dataProduct +DATAPRODUCT_COMPACT=dataProduct_compact +SERVICEOFFERING=serviceOffering + + +FILE_END=.json +RSA_ALGO=PS256 +ISSUER_KEY= "#JWK2020-RSA" +DID=did:web: + +TERMS_AND_CONDITIONS_TEXT="The PARTICIPANT signing the Self-Description agrees as follows:\n- to update its descriptions about any changes, be it technical, organizational, or legal - especially but not limited to contractual in regards to the indicated attributes present in the descriptions.\n\nThe keypair used to sign Verifiable Credentials will be revoked where Gaia-X Association becomes aware of any inaccurate statements in regards to the claims which result in a non-compliance with the Trust Framework and policy rules defined in the Policy Rules and Labelling Document (PRLD)." + +CONTEXT_TC=https://registry.lab.gaia-x.eu/development/api/trusted-shape-registry/v1/shapes/jsonld/trustframework# + +CONTEXT_ITEM1=https://registry.lab.gaia-x.eu/development/api/trusted-shape-registry/v1/shapes/jsonld/trustframework# +CONTEXT_ITEM2=https://www.w3.org/2018/credentials/v1 +CONTEXT_ITEM3=https://w3id.org/security/suites/jws-2020/v1 + +CONTEXT_LRN=https://registry.lab.gaia-x.eu/development/api/trusted-shape-registry/v1/shapes/jsonld/participant + +NOTARIZATION_API=https://registrationnumber.notary.lab.gaia-x.eu/v1/registrationNumberVC +COMPLIANCE_API=https://compliance.lab.gaia-x.eu/v1/api/credential-offers +CREDENTIALS_EVENT_SERVICE_API_v1=https://ces-v1.lab.gaia-x.eu/credentials-events + + +NOTARIZATION_API_DEV=https://registrationnumber.notary.lab.gaia-x.eu/v1-staging/registrationNumberVC +COMPLIANCE_API_DEV=https://compliance.lab.gaia-x.eu/v1-staging/api/credential-offers + + + + + + +ISO_CODES_URL=https://iso3166-2-api.vercel.app/api/subdivision/ +VATCHECKER_API=https://ec.europa.eu/taxation_customs/vies/rest-api/ms/ + + + + +GAIAX_SD_FOLDER=E:\TRABAJO\Proyectos_abiertos\DATAMITE\CODIGO\gaiax-selfdescriptor-module\app\ + +#GAIAX_SD_FOLDER=/var/www/html/.well-known/ + + +NEO4J_IMPORT_FOLDER_LOCAL=E:\TRABAJO\Proyectos_abiertos\DATAMITE\CODIGO\gaiax-selfdescriptor-module\app\ +NEO4J_IMPORT_FOLDER=/var/lib/neo4j/import/ + + + +NEO4J_URI=bolt://datamite:7687 +NEO4J_USER=neo4j +NEO4J_PASSWORD=tecnalia + + +POSTGRES_USER=postgres +POSTGRES_PASSWORD=12345 +POSTGRES_PORT=5432 +POSTGRES_HOST=datamite + + + + +CERTIFICATE_URL=https://datamite.digital.tecnalia.dev/.well-known/x509CertificateChain.pem +#CERTIFICATE_URL=https://gaiax.oasees.digital.tecnalia.dev/.well-known/oasees.crt + + +PRIVATE_KEY="-----BEGIN PRIVATE KEY----- +MIIEvAIBADANBgkqhkiG9w0BAQEFAASCBKYwggSiAgEAAoIBAQCiQU6f0fVkZWmO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I765ki7y1MVcai3vVjS91mL3pGbDfYg1r3fS0ShUKqcEu7ZE2TvtpXwOMTa12MXa +Urbz/GqWw2FUqcJLFloRodkVaA== +-----END PRIVATE KEY-----" + + +#EDC INFO + +PORT=9102 + +POLICY_ID=no-restriction-policy +CONTRACT_ID=contract_no_restriction +#POLICY_TIME_INTERVAL=true +#POLICY_TIME_INTERVAL_START_DATE=2022-12-31T23:00:00.000Z +#POLICY_TIME_INTERVAL_END_DATE=2026-09-30T23:00:00.000Z + +PROVIDER_HOST=hx2023-002.tri.lan +#PROVIDER_HOST=oasees.tri.lan +PROVIDER_CONTROL_PORT=9192 +PROVIDER_MANAGEMENT_PORT=9193 +HEADER_AUTHORIZATION=2dSXJqNXgKAf08PINHOpwTgbcIE5tNgS \ No newline at end of file diff --git a/API_OASEES/requirements.txt b/API_OASEES/requirements.txt new file mode 100644 index 0000000000000000000000000000000000000000..5699722313712a0e7c294ac61b40b9096486f3bc --- /dev/null +++ b/API_OASEES/requirements.txt @@ -0,0 +1,13 @@ +../code/app/local_wheels/datamite-1.0-py2.py3-none-any.whl +uvicorn~=0.27.1 +fastapi~=0.109.2 +cryptography~=42.0.2 +requests~=2.31.0 +jwcrypto~=1.5.3 +PyLD~=2.0.3 +PyJWT~=2.8.0 +validators~=0.22.0 +neo4j~=5.13.0 +pydantic~=2.6.1 +pandas~=2.1.1 +orjson~=3.9.15 diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/APACHE_DOCKER/000-default.conf b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/APACHE_DOCKER/000-default.conf new file mode 100644 index 0000000000000000000000000000000000000000..e3d7921071010b5601467f0cf0f27b50e28c3799 --- /dev/null +++ b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/APACHE_DOCKER/000-default.conf @@ -0,0 +1,37 @@ +<VirtualHost *:80> + # The ServerName directive sets the request scheme, hostname and port that + # the server uses to identify itself. This is used when creating + # redirection URLs. In the context of virtual hosts, the ServerName + # specifies what hostname must appear in the request's Host: header to + # match this virtual host. For the default virtual host (this file) this + # value is not decisive as it is used as a last resort host regardless. + # However, you must set it for any further virtual host explicitly. + #ServerName www.example.com + + ServerAdmin webmaster@localhost + DocumentRoot /var/www/html + ServerName localhost + + + + # Available loglevels: trace8, ..., trace1, debug, info, notice, warn, + # error, crit, alert, emerg. + # It is also possible to configure the loglevel for particular + # modules, e.g. + #LogLevel info ssl:warn + + ErrorLog ${APACHE_LOG_DIR}/error.log + CustomLog ${APACHE_LOG_DIR}/access.log combined + + # For most configuration files from conf-available/, which are + # enabled or disabled at a global level, it is possible to + # include a line for only one particular virtual host. For example the + # following line enables the CGI configuration for this host only + # after it has been globally disabled with "a2disconf". + #Include conf-available/serve-cgi-bin.conf + Redirect "/" "https://gaiax.oasees.digital.tecnalia.dev/" + + +</VirtualHost> + +# vim: syntax=apache ts=4 sw=4 sts=4 sr noet diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/APACHE_DOCKER/Dockerfile b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/APACHE_DOCKER/Dockerfile new file mode 100644 index 0000000000000000000000000000000000000000..8a539481aa529899e64926b1bd112350c38f3d4c --- /dev/null +++ b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/APACHE_DOCKER/Dockerfile @@ -0,0 +1,27 @@ +FROM ubuntu +RUN apt update +RUN apt install -y apache2 +RUN apt install -y apache2-utils +RUN apt clean + +RUN mkdir -p /tmp/www/html/.well-known + + +COPY ./oasees.crt /etc/ssl/certs/oasees.crt +COPY ./SSL1550613.priv /etc/ssl/private/SSL1550613.priv + +COPY ./ssl-params.conf /etc/apache2/conf-available/ssl-params.conf +COPY ./default-ssl.conf /etc/apache2/sites-available/default-ssl.conf +COPY ./000-default.conf /etc/apache2/sites-available/000-default.conf + + + +RUN a2enmod ssl +RUN a2enmod headers +RUN a2ensite default-ssl +RUN a2enconf ssl-params +RUN apache2ctl configtest +EXPOSE 80 +EXPOSE 443 + +CMD ["apache2ctl", "-D", "FOREGROUND"] diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/APACHE_DOCKER/SSL1550613.priv b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/APACHE_DOCKER/SSL1550613.priv new file mode 100644 index 0000000000000000000000000000000000000000..c0e23b360ebb06772f426ae33956ed19c18a2609 --- /dev/null +++ b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/APACHE_DOCKER/SSL1550613.priv @@ -0,0 +1,28 @@ +-----BEGIN PRIVATE KEY----- +MIIEvwIBADANBgkqhkiG9w0BAQEFAASCBKkwggSlAgEAAoIBAQDXHSBmv7aDvKeY +Deq1z6oR/H7RyLnT5Rcx1adFJO7yOcw87Qb7+QiOV0JY05192YUiGRowfBEFZ8YQ +hV7DajftAlzvTh7dSUp4rIhvNxud9DNbnaOi9951MM/sJ1jpEBzQPTLKUjLLt2Fr +Qyz+0SOjXS+hNYheMsU8EhZMg+E6X2M678VY7GIHXGtUhbM6DuvWfGl1FikEb4UU +b8QMN8kJkBpTEzJhDKDP3j/AkISj5HLkX8Q2Sgw8/H2DwPfyfk4gRxcXc1Y1V1J4 +HsTo26TNMqtuRhi6wCIOTROslcX/8uKuQLKQMgJ9kbtXeT4QfZ2/PltCqXjmmBJs +mzdttyM9AgMBAAECggEBANcRXNq9pAnT7S+eAmLiC6RN8LFnYTsUGXuOo90Cjw+I +b8UeKdR0aHR/k2rhr90qQ+wScte0wwPHfAP6hAMWSHHi4e20CjGt3BIIVaPz0d27 +UDmxwu/lp/k84zS1JjRmEpi0Bvq28egxIOov0GW3zUzAlyUzM3MSiZWEc9zuIZnL +/AM+AR4cBHTBThBaQIg4Gj+IrDulilEYjNvc1D5s7Y1GMB/fEjs7L7s/AISQEEkD +7H1CgeWqEKlNSQ23mLen2cN9d41tz5gI1/RIFfZSJSZKxMq6LYT+TRV8aaSsEVzD +gTcwA3y/wn4a6Imiqcj8yUK53plKK1S45ysBGKWot0ECgYEA/Qpiz1Sv2KtAhU22 +93fuKels0fZo9V/2L0irPs6rp5B4kko/HgRGuHJtgjTPoAcw1/y6BEqJ7oV6T7pe +ok4F0uOSiuSEvNgwhXliNwj+bUJZcTiJqwDTF/IwsflyGC848mCaRGTp8J070wUq +BNHYTMaGXL08ctnUISZZuyuRyq0CgYEA2aEvqetCIhQXevu22qk527u8Kn3SYpE4 +fYxfnQJ/9eCtDTqIaGq9MvXLvmc7dPz0SK9J5BlqeQrHdfMLzNBFIzXk+J2KpkP2 +FYhLf+O/To2UcqIa9kewavQ93EVHY5ggMoRR+jShTCpuROp3v+HVCCWCI3Yker7M +v9TWdiwU3NECgYB1txcwjJ0hlsl1OiocBdbt+IF/S7qYLARDCvNfTJXeZf8xTwj9 +1c9wjwsSv663K6E1WYTP6j0wkTfNT04nA1UCPow1wQlfMNOhxE5EfBKgkXU6jqq8 +uq15PloY8Yp6Zb2ARCCAINIT9ZGXIZfilhyh2tk223H7nAprQYQM5r/0IQKBgQCl +5/w3FDL5WcnApq3yKfoCqi67UeoV3FFtXJrzThmQrvQd1pZwy5Zqh/kHsRkhiUkN +NBwneLyzg+Uk5OEFBWz/d7GTWj59m+e46Itt9og78TDO5weY4nP6RTH3fxT6Ntms +yTTZgk/IibxAa2JY9Gd762Q3dnQ+4r+iKjZIJjjNUQKBgQCpNJkwNE092BQ8ByA0 +zRPLAxW/ntX4QzySB4eqe0BHYRfADDw+DCwJBQLlluyb8DJn2GoyY7GMsEBXXxSI +I765ki7y1MVcai3vVjS91mL3pGbDfYg1r3fS0ShUKqcEu7ZE2TvtpXwOMTa12MXa +Urbz/GqWw2FUqcJLFloRodkVaA== +-----END PRIVATE KEY----- \ No newline at end of file diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/APACHE_DOCKER/apache2.conf b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/APACHE_DOCKER/apache2.conf new file mode 100644 index 0000000000000000000000000000000000000000..d45c0d82c1835ee8fde58793d8771db7fe4bdc18 --- /dev/null +++ b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/APACHE_DOCKER/apache2.conf @@ -0,0 +1,228 @@ +# This is the main Apache server configuration file. It contains the +# configuration directives that give the server its instructions. +# See http://httpd.apache.org/docs/2.4/ for detailed information about +# the directives and /usr/share/doc/apache2/README.Debian about Debian specific +# hints. +# +# +# Summary of how the Apache 2 configuration works in Debian: +# The Apache 2 web server configuration in Debian is quite different to +# upstream's suggested way to configure the web server. This is because Debian's +# default Apache2 installation attempts to make adding and removing modules, +# virtual hosts, and extra configuration directives as flexible as possible, in +# order to make automating the changes and administering the server as easy as +# possible. + +# It is split into several files forming the configuration hierarchy outlined +# below, all located in the /etc/apache2/ directory: +# +# /etc/apache2/ +# |-- apache2.conf +# | `-- ports.conf +# |-- mods-enabled +# | |-- *.load +# | `-- *.conf +# |-- conf-enabled +# | `-- *.conf +# `-- sites-enabled +# `-- *.conf +# +# +# * apache2.conf is the main configuration file (this file). It puts the pieces +# together by including all remaining configuration files when starting up the +# web server. +# +# * ports.conf is always included from the main configuration file. It is +# supposed to determine listening ports for incoming connections which can be +# customized anytime. +# +# * Configuration files in the mods-enabled/, conf-enabled/ and sites-enabled/ +# directories contain particular configuration snippets which manage modules, +# global configuration fragments, or virtual host configurations, +# respectively. +# +# They are activated by symlinking available configuration files from their +# respective *-available/ counterparts. These should be managed by using our +# helpers a2enmod/a2dismod, a2ensite/a2dissite and a2enconf/a2disconf. See +# their respective man pages for detailed information. +# +# * The binary is called apache2. Due to the use of environment variables, in +# the default configuration, apache2 needs to be started/stopped with +# /etc/init.d/apache2 or apache2ctl. Calling /usr/bin/apache2 directly will not +# work with the default configuration. + + +# Global configuration +# + +# +# ServerRoot: The top of the directory tree under which the server's +# configuration, error, and log files are kept. +# +# NOTE! If you intend to place this on an NFS (or otherwise network) +# mounted filesystem then please read the Mutex documentation (available +# at <URL:http://httpd.apache.org/docs/2.4/mod/core.html#mutex>); +# you will save yourself a lot of trouble. +# +# Do NOT add a slash at the end of the directory path. +# +#ServerRoot "/etc/apache2" + +# +# The accept serialization lock file MUST BE STORED ON A LOCAL DISK. +# +#Mutex file:${APACHE_LOCK_DIR} default + +# +# The directory where shm and other runtime files will be stored. +# + +DefaultRuntimeDir ${APACHE_RUN_DIR} + +# +# PidFile: The file in which the server should record its process +# identification number when it starts. +# This needs to be set in /etc/apache2/envvars +# +PidFile ${APACHE_PID_FILE} + +# +# Timeout: The number of seconds before receives and sends time out. +# +Timeout 300 + +# +# KeepAlive: Whether or not to allow persistent connections (more than +# one request per connection). Set to "Off" to deactivate. +# +KeepAlive On + +# +# MaxKeepAliveRequests: The maximum number of requests to allow +# during a persistent connection. Set to 0 to allow an unlimited amount. +# We recommend you leave this number high, for maximum performance. +# +MaxKeepAliveRequests 100 + +# +# KeepAliveTimeout: Number of seconds to wait for the next request from the +# same client on the same connection. +# +KeepAliveTimeout 5 + + +# These need to be set in /etc/apache2/envvars +User ${APACHE_RUN_USER} +Group ${APACHE_RUN_GROUP} + +# +# HostnameLookups: Log the names of clients or just their IP addresses +# e.g., www.apache.org (on) or 204.62.129.132 (off). +# The default is off because it'd be overall better for the net if people +# had to knowingly turn this feature on, since enabling it means that +# each client request will result in AT LEAST one lookup request to the +# nameserver. +# +HostnameLookups Off + +# ErrorLog: The location of the error log file. +# If you do not specify an ErrorLog directive within a <VirtualHost> +# container, error messages relating to that virtual host will be +# logged here. If you *do* define an error logfile for a <VirtualHost> +# container, that host's errors will be logged there and not here. +# +ErrorLog ${APACHE_LOG_DIR}/error.log + +# +# LogLevel: Control the severity of messages logged to the error_log. +# Available values: trace8, ..., trace1, debug, info, notice, warn, +# error, crit, alert, emerg. +# It is also possible to configure the log level for particular modules, e.g. +# "LogLevel info ssl:warn" +# +LogLevel warn + +# Include module configuration: +IncludeOptional mods-enabled/*.load +IncludeOptional mods-enabled/*.conf + +# Include list of ports to listen on +Include ports.conf + + +# Sets the default security model of the Apache2 HTTPD server. It does +# not allow access to the root filesystem outside of /usr/share and /var/www. +# The former is used by web applications packaged in Debian, +# the latter may be used for local directories served by the web server. If +# your system is serving content from a sub-directory in /srv you must allow +# access here, or in any related virtual host. +<Directory /> + Options FollowSymLinks + AllowOverride None + Require all denied +</Directory> + +<Directory /usr/share> + AllowOverride None + Require all granted +</Directory> + +<Directory /var/www/> + Options Indexes FollowSymLinks + AllowOverride None + Require all granted +</Directory> + +#<Directory /srv/> +# Options Indexes FollowSymLinks +# AllowOverride None +# Require all granted +#</Directory> + + + + +# AccessFileName: The name of the file to look for in each directory +# for additional configuration directives. See also the AllowOverride +# directive. +# +AccessFileName .htaccess + +# +# The following lines prevent .htaccess and .htpasswd files from being +# viewed by Web clients. +# +<FilesMatch "^\.ht"> + Require all denied +</FilesMatch> + + +# +# The following directives define some format nicknames for use with +# a CustomLog directive. +# +# These deviate from the Common Log Format definitions in that they use %O +# (the actual bytes sent including headers) instead of %b (the size of the +# requested file), because the latter makes it impossible to detect partial +# requests. +# +# Note that the use of %{X-Forwarded-For}i instead of %h is not recommended. +# Use mod_remoteip instead. +# +LogFormat "%v:%p %h %l %u %t \"%r\" %>s %O \"%{Referer}i\" \"%{User-Agent}i\"" vhost_combined +LogFormat "%h %l %u %t \"%r\" %>s %O \"%{Referer}i\" \"%{User-Agent}i\"" combined +LogFormat "%h %l %u %t \"%r\" %>s %O" common +LogFormat "%{Referer}i -> %U" referer +LogFormat "%{User-agent}i" agent + +# Include of directories ignores editors' and dpkg's backup files, +# see README.Debian for details. + +# Include generic snippets of statements +IncludeOptional conf-enabled/*.conf + +# Include the virtual host configurations: +IncludeOptional sites-enabled/*.conf + +# vim: syntax=apache ts=4 sw=4 sts=4 sr noet +ServerName localhost diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/APACHE_DOCKER/default-ssl.conf b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/APACHE_DOCKER/default-ssl.conf new file mode 100644 index 0000000000000000000000000000000000000000..caff2f62621d4da44511bc4e41d91b0ed8a59ff3 --- /dev/null +++ b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/APACHE_DOCKER/default-ssl.conf @@ -0,0 +1,142 @@ +<IfModule mod_ssl.c> + <VirtualHost _default_:443> + + + ServerAdmin urtza.iturraspe@tecnalia.com + ServerName localhost +# ServerAlias gaiax.oasees.digital.tecnalia.dev + + + DocumentRoot /var/www/html + + # Available loglevels: trace8, ..., trace1, debug, info, notice, warn, + # error, crit, alert, emerg. + # It is also possible to configure the loglevel for particular + # modules, e.g. + #LogLevel info ssl:warn + + ErrorLog ${APACHE_LOG_DIR}/error.log + CustomLog ${APACHE_LOG_DIR}/access.log combined + + # For most configuration files from conf-available/, which are + # enabled or disabled at a global level, it is possible to + # include a line for only one particular virtual host. For example the + # following line enables the CGI configuration for this host only + # after it has been globally disabled with "a2disconf". + #Include conf-available/serve-cgi-bin.conf + + # SSL Engine Switch: + # Enable/Disable SSL for this virtual host. + SSLEngine on + + # A self-signed (snakeoil) certificate can be created by installing + # the ssl-cert package. See + # /usr/share/doc/apache2/README.Debian.gz for more info. + # If both key and certificate are stored in the same file, only the + # SSLCertificateFile directive is needed. + #SSLCertificateFile /etc/ssl/certs/ssl-cert-snakeoil.pem + #SSLCertificateKeyFile /etc/ssl/private/ssl-cert-snakeoil.key + SSLCertificateFile /etc/ssl/certs/oasees.crt + SSLCertificateKeyFile /etc/ssl/private/SSL1550613.priv + + + # Server Certificate Chain: + # Point SSLCertificateChainFile at a file containing the + # concatenation of PEM encoded CA certificates which form the + # certificate chain for the server certificate. Alternatively + # the referenced file can be the same as SSLCertificateFile + # when the CA certificates are directly appended to the server + # certificate for convinience. + #SSLCertificateChainFile /etc/apache2/ssl.crt/server-ca.crt + + # Certificate Authority (CA): + # Set the CA certificate verification path where to find CA + # certificates for client authentication or alternatively one + # huge file containing all of them (file must be PEM encoded) + # Note: Inside SSLCACertificatePath you need hash symlinks + # to point to the certificate files. Use the provided + # Makefile to update the hash symlinks after changes. + #SSLCACertificatePath /etc/ssl/certs/ + #SSLCACertificateFile /etc/apache2/ssl.crt/ca-bundle.crt + + # Certificate Revocation Lists (CRL): + # Set the CA revocation path where to find CA CRLs for client + # authentication or alternatively one huge file containing all + # of them (file must be PEM encoded) + # Note: Inside SSLCARevocationPath you need hash symlinks + # to point to the certificate files. Use the provided + # Makefile to update the hash symlinks after changes. + #SSLCARevocationPath /etc/apache2/ssl.crl/ + #SSLCARevocationFile /etc/apache2/ssl.crl/ca-bundle.crl + + # Client Authentication (Type): + # Client certificate verification type and depth. Types are + # none, optional, require and optional_no_ca. Depth is a + # number which specifies how deeply to verify the certificate + # issuer chain before deciding the certificate is not valid. + #SSLVerifyClient require + #SSLVerifyDepth 10 + + # SSL Engine Options: + # Set various options for the SSL engine. + # o FakeBasicAuth: + # Translate the client X.509 into a Basic Authorisation. This means that + # the standard Auth/DBMAuth methods can be used for access control. The + # user name is the `one line' version of the client's X.509 certificate. + # Note that no password is obtained from the user. Every entry in the user + # file needs this password: `xxj31ZMTZzkVA'. + # o ExportCertData: + # This exports two additional environment variables: SSL_CLIENT_CERT and + # SSL_SERVER_CERT. These contain the PEM-encoded certificates of the + # server (always existing) and the client (only existing when client + # authentication is used). This can be used to import the certificates + # into CGI scripts. + # o StdEnvVars: + # This exports the standard SSL/TLS related `SSL_*' environment variables. + # Per default this exportation is switched off for performance reasons, + # because the extraction step is an expensive operation and is usually + # useless for serving static content. So one usually enables the + # exportation for CGI and SSI requests only. + # o OptRenegotiate: + # This enables optimized SSL connection renegotiation handling when SSL + # directives are used in per-directory context. + #SSLOptions +FakeBasicAuth +ExportCertData +StrictRequire + <FilesMatch "\.(cgi|shtml|phtml|php)$"> + SSLOptions +StdEnvVars + </FilesMatch> + <Directory /usr/lib/cgi-bin> + SSLOptions +StdEnvVars + </Directory> + + # SSL Protocol Adjustments: + # The safe and default but still SSL/TLS standard compliant shutdown + # approach is that mod_ssl sends the close notify alert but doesn't wait for + # the close notify alert from client. When you need a different shutdown + # approach you can use one of the following variables: + # o ssl-unclean-shutdown: + # This forces an unclean shutdown when the connection is closed, i.e. no + # SSL close notify alert is send or allowed to received. This violates + # the SSL/TLS standard but is needed for some brain-dead browsers. Use + # this when you receive I/O errors because of the standard approach where + # mod_ssl sends the close notify alert. + # o ssl-accurate-shutdown: + # This forces an accurate shutdown when the connection is closed, i.e. a + # SSL close notify alert is send and mod_ssl waits for the close notify + # alert of the client. This is 100% SSL/TLS standard compliant, but in + # practice often causes hanging connections with brain-dead browsers. Use + # this only for browsers where you know that their SSL implementation + # works correctly. + # Notice: Most problems of broken clients are also related to the HTTP + # keep-alive facility, so you usually additionally want to disable + # keep-alive for those clients, too. Use variable "nokeepalive" for this. + # Similarly, one has to force some clients to use HTTP/1.0 to workaround + # their broken HTTP/1.1 implementation. Use variables "downgrade-1.0" and + # "force-response-1.0" for this. + # BrowserMatch "MSIE [2-6]" \ + # nokeepalive ssl-unclean-shutdown \ + # downgrade-1.0 force-response-1.0 + + </VirtualHost> +</IfModule> + +# vim: syntax=apache ts=4 sw=4 sts=4 sr noet diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/APACHE_DOCKER/docker-compose.yml b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/APACHE_DOCKER/docker-compose.yml new file mode 100644 index 0000000000000000000000000000000000000000..00a77d39fc964ca6489c96d1c5cdd3232769d288 --- /dev/null +++ b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/APACHE_DOCKER/docker-compose.yml @@ -0,0 +1,32 @@ +version: '3.5' + +services: + + + apache: + + build: + context: . + args: + BUILDKIT_INLINE_CACHE: 1 # For multistage docker + container_name: 'oasees-apache-container' +# hostname: 172.17.40.50 + + ports: + - 80:80 + - 443:443 + volumes: + - $HOME/apacheDir:/var/www/html/.well-known + extra_hosts: + - "gaiax.oasees..digital.tecnalia.dev:172.26.41.12" + networks: + - oasees + + + +networks: + oasees: + +volumes: + app: {} + diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/APACHE_DOCKER/oasees.crt b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/APACHE_DOCKER/oasees.crt new file mode 100644 index 0000000000000000000000000000000000000000..b82eec06e7d60fd91dbad3b8afa30f29a3c8466b --- /dev/null +++ b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/APACHE_DOCKER/oasees.crt @@ -0,0 +1,85 @@ +-----BEGIN CERTIFICATE----- +MIIGLTCCBRWgAwIBAgIQDtKGvgv2XuOXwxOtPMgy4zANBgkqhkiG9w0BAQsFADBe +MQswCQYDVQQGEwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQLExB3 +d3cuZGlnaWNlcnQuY29tMR0wGwYDVQQDExRUaGF3dGUgVExTIFJTQSBDQSBHMTAe +Fw0yNDAyMjcwMDAwMDBaFw0yNTAyMjYyMzU5NTlaMCgxJjAkBgNVBAMMHSoub2Fz +ZWVzLmRpZ2l0YWwudGVjbmFsaWEuZGV2MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8A +MIIBCgKCAQEA1x0gZr+2g7ynmA3qtc+qEfx+0ci50+UXMdWnRSTu8jnMPO0G+/kI +jldCWNOdfdmFIhkaMHwRBWfGEIVew2o37QJc704e3UlKeKyIbzcbnfQzW52jovfe +dTDP7CdY6RAc0D0yylIyy7dha0Ms/tEjo10voTWIXjLFPBIWTIPhOl9jOu/FWOxi +B1xrVIWzOg7r1nxpdRYpBG+FFG/EDDfJCZAaUxMyYQygz94/wJCEo+Ry5F/ENkoM +PPx9g8D38n5OIEcXF3NWNVdSeB7E6NukzTKrbkYYusAiDk0TrJXF//LirkCykDIC +fZG7V3k+EH2dvz5bQql45pgSbJs3bbcjPQIDAQABo4IDGzCCAxcwHwYDVR0jBBgw +FoAUpYz+MszrDyzUGcYIuAAkiF3DxbcwHQYDVR0OBBYEFOnvx0n9IfJjm+ICWmcT +pb22LxjLMCgGA1Ud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rY= +-----END CERTIFICATE----- diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/APACHE_DOCKER/ssl-params.conf b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/APACHE_DOCKER/ssl-params.conf new file mode 100644 index 0000000000000000000000000000000000000000..56f8ebceb0e1df1877d4143ff99e1dbdbd539d24 --- /dev/null +++ b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/APACHE_DOCKER/ssl-params.conf @@ -0,0 +1,14 @@ +SSLCipherSuite EECDH+AESGCM:EDH+AESGCM:AES256+EECDH:AES256+EDH +SSLProtocol All -SSLv2 -SSLv3 -TLSv1 -TLSv1.1 +SSLHonorCipherOrder On +# Disable preloading HSTS for now. You can use the commented out header line that includes +# the "preload" directive if you understand the implications. +# Header always set Strict-Transport-Security "max-age=63072000; includeSubDomains; preload" +Header always set X-Frame-Options DENY +Header always set X-Content-Type-Options nosniff +# Requires Apache >= 2.4 +SSLCompression off +SSLUseStapling on +SSLStaplingCache "shmcb:logs/stapling-cache(150000)" +# Requires Apache >= 2.4.11 +SSLSessionTickets Off diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/docker-compose.yml b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/docker-compose.yml new file mode 100644 index 0000000000000000000000000000000000000000..1fb0fca97d091020be9af76b7b79b88313b6c767 --- /dev/null +++ b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/docker-compose.yml @@ -0,0 +1,87 @@ +version: '3.5' + +services: + + + apache: + + build: + context: ./APACHE_DOCKER + args: + BUILDKIT_INLINE_CACHE: 1 # For multistage docker + container_name: 'oasees-apache-container' + + ports: + - 80:80 + - 443:443 + volumes: + - $HOME/apacheDir:/var/www/html/.well-known + extra_hosts: + - "gaiax.oasees.digital.tecnalia.dev:172.26.41.12" + networks: + - oasees-network + + gaiax_selfdescriptor_module: + container_name: gaiax_selfdescriptor_module + build: + context: ./gaiax-selfdescriptor-module + restart: always + env_file: + - oasees.env + volumes: + - ./gaiax-selfdescriptor-module:/code + - $HOME/apacheDir:/var/www/html/.well-known + - $HOME/neo4j/import:/var/lib/neo4j/import + + extra_hosts: + - "gaiax.oasees.digital.tecnalia.dev:172.26.41.12" + + ports: + - 9102:8500 + + networks: + - oasees-network + + neo4j: + image: neo4j:5.7.0 + container_name: oasees_neo4j + ports: + - 7474:7474 + - 7687:7687 + env_file: + - ./neo4j.env + volumes: + - $HOME/neo4j/data:/data + - $HOME/neo4j/logs:/logs + - $HOME/neo4j/import:/var/lib/neo4j/import + - $HOME/neo4j/plugins:/plugins + networks: + - oasees-network + + postgres: + image: postgres:10.5 + container_name: oasees_postgres + restart: always + environment: + - POSTGRES_USER=postgres + - POSTGRES_PASSWORD=12345 + logging: + options: + max-size: 10m + max-file: "3" + ports: + - '5432:5432' + + volumes: + - ./postgres-data:/var/lib/postgresql/data + # copy the sql script to create tables + - ./sql/create_tables.sql:/docker-entrypoint-initdb.d/create_tables.sql + networks: + - oasees-network +volumes: + app: {} + +networks: + oasees-network: + name: oasees-network + driver: bridge diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/Dockerfile b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/Dockerfile new file mode 100644 index 0000000000000000000000000000000000000000..4dc3a899fdc87597758a02ae6bc110102170cfe5 --- /dev/null +++ b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/Dockerfile @@ -0,0 +1,16 @@ +FROM python:3.10-alpine + +# Set environment varibles +ENV PORT 8500 + +COPY ./app /code/app +COPY ./requirements.txt /code/app/requirements.txt +# RUN chmod 664 /code/app/model/model.tflite + +# Install dependencies +RUN pip3 install psycopg2-binary +RUN pip3 install -r /code/app/requirements.txt + +WORKDIR /code/ + +CMD uvicorn app.main:app --host 0.0.0.0 --port ${PORT} diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/LICENSE b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..d6091d6b0f55b46fc77df106ab7cb77d48423388 --- /dev/null +++ b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/LICENSE @@ -0,0 +1,288 @@ +EUROPEAN UNION PUBLIC LICENCE v. 1.2 + EUPL © the European Union 2007, 2016 + +This European Union Public Licence (the ‘EUPL’) applies to the Work (as defined +below) which is provided under the terms of this Licence. Any use of the Work, +other than as authorised under this Licence is prohibited (to the extent such +use is covered by a right of the copyright holder of the Work). + +The Work is provided under the terms of this Licence when the Licensor (as +defined below) has placed the following notice immediately following the +copyright notice for the Work: + + Licensed under the EUPL + +or has expressed by any other means his willingness to license under the EUPL. + +1. Definitions + +In this Licence, the following terms have the following meaning: + +- ‘The Licence’: this Licence. + +- ‘The Original Work’: the work or software distributed or communicated by the + Licensor under this Licence, available as Source Code and also as Executable + Code as the case may be. + +- ‘Derivative Works’: the works or software that could be created by the + Licensee, based upon the Original Work or modifications thereof. This Licence + does not define the extent of modification or dependence on the Original Work + required in order to classify a work as a Derivative Work; this extent is + determined by copyright law applicable in the country mentioned in Article 15. + +- ‘The Work’: the Original Work or its Derivative Works. + +- ‘The Source Code’: the human-readable form of the Work which is the most + convenient for people to study and modify. + +- ‘The Executable Code’: any code which has generally been compiled and which is + meant to be interpreted by a computer as a program. + +- ‘The Licensor’: the natural or legal person that distributes or communicates + the Work under the Licence. + +- ‘Contributor(s)’: any natural or legal person who modifies the Work under the + Licence, or otherwise contributes to the creation of a Derivative Work. + +- ‘The Licensee’ or ‘You’: any natural or legal person who makes any usage of + the Work under the terms of the Licence. + +- ‘Distribution’ or ‘Communication’: any act of selling, giving, lending, + renting, distributing, communicating, transmitting, or otherwise making + available, online or offline, copies of the Work or providing access to its + essential functionalities at the disposal of any other natural or legal + person. + +2. Scope of the rights granted by the Licence + +The Licensor hereby grants You a worldwide, royalty-free, non-exclusive, +sublicensable licence to do the following, for the duration of copyright vested +in the Original Work: + +- use the Work in any circumstance and for all usage, +- reproduce the Work, +- modify the Work, and make Derivative Works based upon the Work, +- communicate to the public, including the right to make available or display + the Work or copies thereof to the public and perform publicly, as the case may + be, the Work, +- distribute the Work or copies thereof, +- lend and rent the Work or copies thereof, +- sublicense rights in the Work or copies thereof. + +Those rights can be exercised on any media, supports and formats, whether now +known or later invented, as far as the applicable law permits so. + +In the countries where moral rights apply, the Licensor waives his right to +exercise his moral right to the extent allowed by law in order to make effective +the licence of the economic rights here above listed. + +The Licensor grants to the Licensee royalty-free, non-exclusive usage rights to +any patents held by the Licensor, to the extent necessary to make use of the +rights granted on the Work under this Licence. + +3. Communication of the Source Code + +The Licensor may provide the Work either in its Source Code form, or as +Executable Code. If the Work is provided as Executable Code, the Licensor +provides in addition a machine-readable copy of the Source Code of the Work +along with each copy of the Work that the Licensor distributes or indicates, in +a notice following the copyright notice attached to the Work, a repository where +the Source Code is easily and freely accessible for as long as the Licensor +continues to distribute or communicate the Work. + +4. Limitations on copyright + +Nothing in this Licence is intended to deprive the Licensee of the benefits from +any exception or limitation to the exclusive rights of the rights owners in the +Work, of the exhaustion of those rights or of other applicable limitations +thereto. + +5. Obligations of the Licensee + +The grant of the rights mentioned above is subject to some restrictions and +obligations imposed on the Licensee. Those obligations are the following: + +Attribution right: The Licensee shall keep intact all copyright, patent or +trademarks notices and all notices that refer to the Licence and to the +disclaimer of warranties. The Licensee must include a copy of such notices and a +copy of the Licence with every copy of the Work he/she distributes or +communicates. The Licensee must cause any Derivative Work to carry prominent +notices stating that the Work has been modified and the date of modification. + +Copyleft clause: If the Licensee distributes or communicates copies of the +Original Works or Derivative Works, this Distribution or Communication will be +done under the terms of this Licence or of a later version of this Licence +unless the Original Work is expressly distributed only under this version of the +Licence — for example by communicating ‘EUPL v. 1.2 only’. The Licensee +(becoming Licensor) cannot offer or impose any additional terms or conditions on +the Work or Derivative Work that alter or restrict the terms of the Licence. + +Compatibility clause: If the Licensee Distributes or Communicates Derivative +Works or copies thereof based upon both the Work and another work licensed under +a Compatible Licence, this Distribution or Communication can be done under the +terms of this Compatible Licence. For the sake of this clause, ‘Compatible +Licence’ refers to the licences listed in the appendix attached to this Licence. +Should the Licensee's obligations under the Compatible Licence conflict with +his/her obligations under this Licence, the obligations of the Compatible +Licence shall prevail. + +Provision of Source Code: When distributing or communicating copies of the Work, +the Licensee will provide a machine-readable copy of the Source Code or indicate +a repository where this Source will be easily and freely available for as long +as the Licensee continues to distribute or communicate the Work. + +Legal Protection: This Licence does not grant permission to use the trade names, +trademarks, service marks, or names of the Licensor, except as required for +reasonable and customary use in describing the origin of the Work and +reproducing the content of the copyright notice. + +6. Chain of Authorship + +The original Licensor warrants that the copyright in the Original Work granted +hereunder is owned by him/her or licensed to him/her and that he/she has the +power and authority to grant the Licence. + +Each Contributor warrants that the copyright in the modifications he/she brings +to the Work are owned by him/her or licensed to him/her and that he/she has the +power and authority to grant the Licence. + +Each time You accept the Licence, the original Licensor and subsequent +Contributors grant You a licence to their contributions to the Work, under the +terms of this Licence. + +7. Disclaimer of Warranty + +The Work is a work in progress, which is continuously improved by numerous +Contributors. It is not a finished work and may therefore contain defects or +‘bugs’ inherent to this type of development. + +For the above reason, the Work is provided under the Licence on an ‘as is’ basis +and without warranties of any kind concerning the Work, including without +limitation merchantability, fitness for a particular purpose, absence of defects +or errors, accuracy, non-infringement of intellectual property rights other than +copyright as stated in Article 6 of this Licence. + +This disclaimer of warranty is an essential part of the Licence and a condition +for the grant of any rights to the Work. + +8. Disclaimer of Liability + +Except in the cases of wilful misconduct or damages directly caused to natural +persons, the Licensor will in no event be liable for any direct or indirect, +material or moral, damages of any kind, arising out of the Licence or of the use +of the Work, including without limitation, damages for loss of goodwill, work +stoppage, computer failure or malfunction, loss of data or any commercial +damage, even if the Licensor has been advised of the possibility of such damage. +However, the Licensor will be liable under statutory product liability laws as +far such laws apply to the Work. + +9. Additional agreements + +While distributing the Work, You may choose to conclude an additional agreement, +defining obligations or services consistent with this Licence. However, if +accepting obligations, You may act only on your own behalf and on your sole +responsibility, not on behalf of the original Licensor or any other Contributor, +and only if You agree to indemnify, defend, and hold each Contributor harmless +for any liability incurred by, or claims asserted against such Contributor by +the fact You have accepted any warranty or additional liability. + +10. Acceptance of the Licence + +The provisions of this Licence can be accepted by clicking on an icon ‘I agree’ +placed under the bottom of a window displaying the text of this Licence or by +affirming consent in any other similar way, in accordance with the rules of +applicable law. Clicking on that icon indicates your clear and irrevocable +acceptance of this Licence and all of its terms and conditions. + +Similarly, you irrevocably accept this Licence and all of its terms and +conditions by exercising any rights granted to You by Article 2 of this Licence, +such as the use of the Work, the creation by You of a Derivative Work or the +Distribution or Communication by You of the Work or copies thereof. + +11. Information to the public + +In case of any Distribution or Communication of the Work by means of electronic +communication by You (for example, by offering to download the Work from a +remote location) the distribution channel or media (for example, a website) must +at least provide to the public the information requested by the applicable law +regarding the Licensor, the Licence and the way it may be accessible, concluded, +stored and reproduced by the Licensee. + +12. Termination of the Licence + +The Licence and the rights granted hereunder will terminate automatically upon +any breach by the Licensee of the terms of the Licence. + +Such a termination will not terminate the licences of any person who has +received the Work from the Licensee under the Licence, provided such persons +remain in full compliance with the Licence. + +13. Miscellaneous + +Without prejudice of Article 9 above, the Licence represents the complete +agreement between the Parties as to the Work. + +If any provision of the Licence is invalid or unenforceable under applicable +law, this will not affect the validity or enforceability of the Licence as a +whole. Such provision will be construed or reformed so as necessary to make it +valid and enforceable. + +The European Commission may publish other linguistic versions or new versions of +this Licence or updated versions of the Appendix, so far this is required and +reasonable, without reducing the scope of the rights granted by the Licence. New +versions of the Licence will be published with a unique version number. + +All linguistic versions of this Licence, approved by the European Commission, +have identical value. Parties can take advantage of the linguistic version of +their choice. + +14. Jurisdiction + +Without prejudice to specific agreement between parties, + +- any litigation resulting from the interpretation of this License, arising + between the European Union institutions, bodies, offices or agencies, as a + Licensor, and any Licensee, will be subject to the jurisdiction of the Court + of Justice of the European Union, as laid down in article 272 of the Treaty on + the Functioning of the European Union, + +- any litigation arising between other parties and resulting from the + interpretation of this License, will be subject to the exclusive jurisdiction + of the competent court where the Licensor resides or conducts its primary + business. + +15. Applicable Law + +Without prejudice to specific agreement between parties, + +- this Licence shall be governed by the law of the European Union Member State + where the Licensor has his seat, resides or has his registered office, + +- this licence shall be governed by Belgian law if the Licensor has no seat, + residence or registered office inside a European Union Member State. + +Appendix + +‘Compatible Licences’ according to Article 5 EUPL are: + +- GNU General Public License (GPL) v. 2, v. 3 +- GNU Affero General Public License (AGPL) v. 3 +- Open Software License (OSL) v. 2.1, v. 3.0 +- Eclipse Public License (EPL) v. 1.0 +- CeCILL v. 2.0, v. 2.1 +- Mozilla Public Licence (MPL) v. 2 +- GNU Lesser General Public Licence (LGPL) v. 2.1, v. 3 +- Creative Commons Attribution-ShareAlike v. 3.0 Unported (CC BY-SA 3.0) for + works other than software +- European Union Public Licence (EUPL) v. 1.1, v. 1.2 +- Québec Free and Open-Source Licence — Reciprocity (LiLiQ-R) or Strong + Reciprocity (LiLiQ-R+). + +The European Commission may update this Appendix to later versions of the above +licences without producing a new version of the EUPL, as long as they provide +the rights granted in Article 2 of this Licence and protect the covered Source +Code from exclusive appropriation. + +All other changes or additions to this Appendix require the production of a new +EUPL version. + diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/__init__.py b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/PyJWT-2.8.0-py3-none-any.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/PyJWT-2.8.0-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..8d3635002b36bf9551f6302cc9fc6a09a4faba5c Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/PyJWT-2.8.0-py3-none-any.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/PyLD-2.0.4-py3-none-any.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/PyLD-2.0.4-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..67b5edfc66d077e70b8766a2276344346ce4ee92 Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/PyLD-2.0.4-py3-none-any.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/annotated_types-0.6.0-py3-none-any.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/annotated_types-0.6.0-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..acb80e7d58c4052a81f7b9a373662c8b20ad662f Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/annotated_types-0.6.0-py3-none-any.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/anyio-4.3.0-py3-none-any.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/anyio-4.3.0-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..3e95a11d45107f120f4489cca88aac49802d9a96 Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/anyio-4.3.0-py3-none-any.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/cachetools-5.3.3-py3-none-any.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/cachetools-5.3.3-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..c0676942fe430d045156850d14ca1c294550d9f7 Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/cachetools-5.3.3-py3-none-any.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/certifi-2024.2.2-py3-none-any.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/certifi-2024.2.2-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..450e3bd709d1da5a7c7f89e1cbb7b7e5841a6992 Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/certifi-2024.2.2-py3-none-any.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/cffi-1.16.0-cp310-cp310-win_amd64.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/cffi-1.16.0-cp310-cp310-win_amd64.whl new file mode 100644 index 0000000000000000000000000000000000000000..e1e9c27184fc26c5711819a7637f9cf934b42e23 Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/cffi-1.16.0-cp310-cp310-win_amd64.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/charset_normalizer-3.3.2-cp310-cp310-win_amd64.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/charset_normalizer-3.3.2-cp310-cp310-win_amd64.whl new file mode 100644 index 0000000000000000000000000000000000000000..8362ebcf5169a5eb66ef371310d7e36ce390f1cc Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/charset_normalizer-3.3.2-cp310-cp310-win_amd64.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/click-8.1.7-py3-none-any.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/click-8.1.7-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..5e8a550d5bfd9bfbd8be80395361d54318f10764 Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/click-8.1.7-py3-none-any.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/colorama-0.4.6-py2.py3-none-any.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/colorama-0.4.6-py2.py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..f666ce989f84a46703ead9fa296a74c24e60b590 Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/colorama-0.4.6-py2.py3-none-any.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/cryptography-42.0.5-cp39-abi3-win_amd64.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/cryptography-42.0.5-cp39-abi3-win_amd64.whl new file mode 100644 index 0000000000000000000000000000000000000000..6654b17e45e5e450f48a485f57c0c1bf16197d2f Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/cryptography-42.0.5-cp39-abi3-win_amd64.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/cryptography-42.0.6-cp39-abi3-win_amd64.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/cryptography-42.0.6-cp39-abi3-win_amd64.whl new file mode 100644 index 0000000000000000000000000000000000000000..bdb9cf56c55a35b5f9bb5ff740428e75550aa63e Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/cryptography-42.0.6-cp39-abi3-win_amd64.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/cryptography-42.0.7-cp39-abi3-win_amd64.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/cryptography-42.0.7-cp39-abi3-win_amd64.whl new file mode 100644 index 0000000000000000000000000000000000000000..19c0fa8b6eaa876084e3367476ca3e25c4888e57 Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/cryptography-42.0.7-cp39-abi3-win_amd64.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/datamite-1.0-py2.py3-none-any.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/datamite-1.0-py2.py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..b943f85a9f06fc30c6815cbd47bdad8ea5ff232c Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/datamite-1.0-py2.py3-none-any.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/datamite-1.8-py2.py3-none-any.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/datamite-1.8-py2.py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..7c3520d4a8e1bfafa2b1d714dcdceb7171c0c0d8 Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/datamite-1.8-py2.py3-none-any.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/datamite-1.9-py2.py3-none-any.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/datamite-1.9-py2.py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..f5709e5f760409464b7cfcb5f6286329a943a170 Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/datamite-1.9-py2.py3-none-any.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/exceptiongroup-1.2.0-py3-none-any.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/exceptiongroup-1.2.0-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..9195d365ff67b00d70ac2f40d375600049a32c00 Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/exceptiongroup-1.2.0-py3-none-any.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/exceptiongroup-1.2.1-py3-none-any.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/exceptiongroup-1.2.1-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..494f2626e8221a08ed97b10c6f15db1ffe1649e3 Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/exceptiongroup-1.2.1-py3-none-any.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/fastapi-0.109.2-py3-none-any.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/fastapi-0.109.2-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..d63b090557b4b96ee03ef0cb2bd3c9ecb88e63d2 Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/fastapi-0.109.2-py3-none-any.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/frozendict-2.4.0-cp310-cp310-win_amd64.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/frozendict-2.4.0-cp310-cp310-win_amd64.whl new file mode 100644 index 0000000000000000000000000000000000000000..1f214c2827d30219ddfbffef3d2d126384918a4e Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/frozendict-2.4.0-cp310-cp310-win_amd64.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/frozendict-2.4.1-cp310-cp310-win_amd64.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/frozendict-2.4.1-cp310-cp310-win_amd64.whl new file mode 100644 index 0000000000000000000000000000000000000000..1e6102045ec57a5d6e16c61ab2d0f63a3fc85212 Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/frozendict-2.4.1-cp310-cp310-win_amd64.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/frozendict-2.4.3-cp310-cp310-win_amd64.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/frozendict-2.4.3-cp310-cp310-win_amd64.whl new file mode 100644 index 0000000000000000000000000000000000000000..e5471b664af5a684e8cd8efd68b15c78049dca7b Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/frozendict-2.4.3-cp310-cp310-win_amd64.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/frozendict-2.4.4-cp310-cp310-win_amd64.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/frozendict-2.4.4-cp310-cp310-win_amd64.whl new file mode 100644 index 0000000000000000000000000000000000000000..c11798c3ae7486cb2921728fb142d3e6c29d238f Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/frozendict-2.4.4-cp310-cp310-win_amd64.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/h11-0.14.0-py3-none-any.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/h11-0.14.0-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..a02c8de7c1c4c5fa7825d707cf79071c1a980df7 Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/h11-0.14.0-py3-none-any.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/idna-3.6-py3-none-any.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/idna-3.6-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..fdf65ae30cb847fd4742dd28aa5027d9e569f885 Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/idna-3.6-py3-none-any.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/idna-3.7-py3-none-any.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/idna-3.7-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..fa4c95b123751094438c2f747e5389c32d870c5b Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/idna-3.7-py3-none-any.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/jwcrypto-1.5.6-py3-none-any.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/jwcrypto-1.5.6-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..e2a712c9296144407618625c97874f96115812cf Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/jwcrypto-1.5.6-py3-none-any.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/lxml-5.1.0-cp310-cp310-win_amd64.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/lxml-5.1.0-cp310-cp310-win_amd64.whl new file mode 100644 index 0000000000000000000000000000000000000000..844b4ceb5e89ae122ef1e7ad03d7a47102f183a9 Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/lxml-5.1.0-cp310-cp310-win_amd64.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/lxml-5.2.0-cp310-cp310-win_amd64.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/lxml-5.2.0-cp310-cp310-win_amd64.whl new file mode 100644 index 0000000000000000000000000000000000000000..0db33544e75dd19eccbb8c63ade69174ebe85677 Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/lxml-5.2.0-cp310-cp310-win_amd64.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/lxml-5.2.1-cp310-cp310-win_amd64.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/lxml-5.2.1-cp310-cp310-win_amd64.whl new file mode 100644 index 0000000000000000000000000000000000000000..489b0e373bb0ad45fcffd2e8e7caed6672f12fb1 Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/lxml-5.2.1-cp310-cp310-win_amd64.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/lxml-5.2.2-cp310-cp310-win_amd64.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/lxml-5.2.2-cp310-cp310-win_amd64.whl new file mode 100644 index 0000000000000000000000000000000000000000..c88e449ade92b39a076806a7bf8ce9f8e5bb95b3 Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/lxml-5.2.2-cp310-cp310-win_amd64.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/neo4j-5.13.0-py3-none-any.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/neo4j-5.13.0-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..37b81ba33aba47f8f4726e151ffb12b27e4533d3 Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/neo4j-5.13.0-py3-none-any.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/numpy-1.26.4-cp310-cp310-win_amd64.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/numpy-1.26.4-cp310-cp310-win_amd64.whl new file mode 100644 index 0000000000000000000000000000000000000000..3886f83b73e94109ffd22f2bad024b5004b26f1c Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/numpy-1.26.4-cp310-cp310-win_amd64.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/orjson-3.9.15-cp310-none-win_amd64.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/orjson-3.9.15-cp310-none-win_amd64.whl new file mode 100644 index 0000000000000000000000000000000000000000..da9d1605b63f89006c1cdc787810083d4683821d Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/orjson-3.9.15-cp310-none-win_amd64.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/pandas-2.1.4-cp310-cp310-win_amd64.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/pandas-2.1.4-cp310-cp310-win_amd64.whl new file mode 100644 index 0000000000000000000000000000000000000000..c2929705a2fca323b04df719cb7a10b145d385fb Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/pandas-2.1.4-cp310-cp310-win_amd64.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/pycparser-2.21-py2.py3-none-any.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/pycparser-2.21-py2.py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..fef6735a27d21820e27aeec8991df1cb1996a3f9 Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/pycparser-2.21-py2.py3-none-any.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/pycparser-2.22-py3-none-any.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/pycparser-2.22-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..b47818710e16179213829ac49a44467f01e35bb4 Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/pycparser-2.22-py3-none-any.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/pydantic-2.6.4-py3-none-any.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/pydantic-2.6.4-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..1fae395065b9e865669ce58a447af7818813fbaf Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/pydantic-2.6.4-py3-none-any.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/pydantic_core-2.16.3-cp310-none-win_amd64.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/pydantic_core-2.16.3-cp310-none-win_amd64.whl new file mode 100644 index 0000000000000000000000000000000000000000..83b2b96c9de00175b348d24b442375f30beba693 Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/pydantic_core-2.16.3-cp310-none-win_amd64.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/python_dateutil-2.9.0.post0-py2.py3-none-any.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/python_dateutil-2.9.0.post0-py2.py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..b9a14e1bf98404e31ba5398c4d84cbd76dcf8e84 Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/python_dateutil-2.9.0.post0-py2.py3-none-any.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/pytz-2024.1-py2.py3-none-any.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/pytz-2024.1-py2.py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..571f586a0d36210442b50278b757b07fc37fdbba Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/pytz-2024.1-py2.py3-none-any.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/requests-2.31.0-py3-none-any.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/requests-2.31.0-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..bfd5d2ea99d7b026e75e9aa393a0cad8f829efb5 Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/requests-2.31.0-py3-none-any.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/six-1.16.0-py2.py3-none-any.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/six-1.16.0-py2.py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..fd942658a2f748ba433dd8632abb910a416e184f Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/six-1.16.0-py2.py3-none-any.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/sniffio-1.3.1-py3-none-any.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/sniffio-1.3.1-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..04f44e47d69d33e39c88ce206e3f100443083f17 Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/sniffio-1.3.1-py3-none-any.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/starlette-0.36.3-py3-none-any.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/starlette-0.36.3-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..318486f92010faf79d0ca20336751cabfbbe193b Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/starlette-0.36.3-py3-none-any.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/typing_extensions-4.10.0-py3-none-any.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/typing_extensions-4.10.0-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..ce56f2ad9b8548f242bc18b7c172c31c7d99c0db Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/typing_extensions-4.10.0-py3-none-any.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/typing_extensions-4.11.0-py3-none-any.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/typing_extensions-4.11.0-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..117651413b720616806f443664561004a0302de2 Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/typing_extensions-4.11.0-py3-none-any.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/tzdata-2024.1-py2.py3-none-any.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/tzdata-2024.1-py2.py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..236fda48d735fd0b3856b387e137bbb10529953b Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/tzdata-2024.1-py2.py3-none-any.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/urllib3-2.2.1-py3-none-any.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/urllib3-2.2.1-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..d7cca6a473137e22739248c814ef561b2f8fccc4 Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/urllib3-2.2.1-py3-none-any.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/uvicorn-0.27.1-py3-none-any.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/uvicorn-0.27.1-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..b9589930ee2e4b139b477978b1dae6e7e6b20bfc Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/uvicorn-0.27.1-py3-none-any.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/validators-0.22.0-py3-none-any.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/validators-0.22.0-py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..00cadb1ed1036ab19b0d19ec4bdb625b09cba77b Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/local_wheels/validators-0.22.0-py3-none-any.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/main.py b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/main.py new file mode 100644 index 0000000000000000000000000000000000000000..30f9ff790cf7427afa34d5f5f9143a51a3e9eac2 --- /dev/null +++ b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/main.py @@ -0,0 +1,246 @@ +import logging +import os +import sys +import uvicorn +from datamite.models.dataProductResourcesBody import DataProductResourcesModel +from datamite.models.legalParticipantBodyModel import LegalParticipantBodyModel +from datamite.utils.certificate_utils import sign_doc, signVeriablePresentation +from datamite.utils.gaiax_utils import callCredentialsEventService, callComplianceAPI +from datamite.utils.neo4j_utils import loadInNeo4j, getData_productsList, getData_productsByName +from datamite.utils.postgres_utils import getCesData +from datamite.utils.selfDescription_utils import createDidDocument, \ + createLegalParticipantVerifiablePresentation, \ + createDataProductWithResourcesVerifiablePresentation, \ + createAndPublishDataProductWithResourcesVerifiablePresentation +from fastapi import FastAPI + +from app.utils.connector_utils import load_asset_edc + + +from contextlib import asynccontextmanager + + +tags_metadata = [ + { + "name": "Oasees API" + }, + { + "name": "Oasees testing API" + }, +] + + + + + +logger = logging.getLogger("uvicorn.error") + +DEBUG = os.getenv("DEBUG") or False + + + +@asynccontextmanager +async def lifespan(app: FastAPI): + logger = logging.getLogger("uvicorn.error") + handler = logging.StreamHandler() + handler.setFormatter(logging.Formatter("%(asctime)s | %(levelname)s | %(module)s | %(funcName)s | %(message)s")) + logger.addHandler(handler) + logging_level = logging.INFO + if DEBUG: + logging_level = logging.DEBUG + logger.setLevel(logging_level) + logger.propagate = False + yield + + + +app = FastAPI(lifespan=lifespan, title="Oasees", description=f"Oasees API documentation", openapi_tags=tags_metadata) + + +####################################################################### +# Create a did.json file +#Output: json document for the did +####################################################################### +@app.post("/diddocument", tags=["Oasees API"]) + +async def create_did(domain:str): + + return createDidDocument(domain) + + + + + +####################################################################### +# Create a Gaia-X Legal Participant +#Input: mandatory input data +#Output: JSON for LegalParticipant signed/unsigned +####################################################################### + + +@app.post("/legalparticipant", tags=["Oasees API"]) + + +async def createLegalParticipant(body:LegalParticipantBodyModel): + + return createLegalParticipantVerifiablePresentation (body) + + +####################################################################### +# Create a definition for a DataProduct/Service Offering +#Input: mandatory input data +#Output: JSON for DataProduct/Service signed/unsigned +####################################################################### +""" +@app.post("/createDataProduct", tags=["Datamite External API"]) +async def createDataProduct(body:DataProductBodyModel): + + return createDataProductVeriableCredential(body) +""" + +####################################################################### +# Create a definition for a DataProduct/Service Offering with resources DataResources +#Input: mandatory input data +#Output: JSON for DataProduct/Service Offering with DataResources +####################################################################### + +@app.post("/dataproducts", tags=["Oasees API"]) + +async def createDataProductWithResources(body:DataProductResourcesModel): + + return createDataProductWithResourcesVerifiablePresentation(body) + + + + + +####################################################################### +# Create a definition for a DataProduct/Service Offering with resources DataResources +#Input: mandatory input data +#Output: JSON for DataProduct/Service Offering with DataResources +####################################################################### +@app.post("/publish-dataproduct", tags=["Oasees API"]) + +async def createAndPublishDataProduct(body:DataProductResourcesModel, dataResourceURL:str): + + output=createAndPublishDataProductWithResourcesVerifiablePresentation(body) + print("Output create and publish data product with resources") + print (output) + #output="CES" + outputEDC = load_asset_edc(body, dataResourceURL) + print (outputEDC) + if "CES" in output and outputEDC: + return output + + + +####################################################################### +# Method for getting dataProducts from Neo4j + +#Output: list of dataProducts +####################################################################### +@app.get("/dataproducts", tags=["Oasees API"]) + +async def getDataProductsList(): + + return getData_productsList() + + + +####################################################################### +# Method for getting dataProducts by name from Neo4j + +#Output: dataProduct Name +####################################################################### +@app.get("/dataproducts/{dataProductName}", tags=["Oasees API"]) + +async def getDataProductByName(dataProductName:str): + + return getData_productsByName(dataProductName) + +####################################################################### +# Method for getting CesRecords + +#Output: cesProducts +####################################################################### +@app.get("/cesrecords", tags=["Oasees API"]) + +async def getCesRecords(): + + return getCesData() + + + +####################################################################### +# Sign a verifiable credential +#Input: data for being signed and domain +#Output: data signed +####################################################################### +@app.post("/signVC", tags=["Oasees testing API"]) + + +async def signVC(data: dict , issuerKey:str): + + return sign_doc(data,issuerKey) + + +####################################################################### +# Sign a verifiable presentation +#Input: data for being signed and domain +#Output: data signed +####################################################################### +@app.post("/sign-vp", tags=["Oasees testing API"]) + +async def signVP(data: dict , domain:str): + + + return signVeriablePresentation(data,domain) + + + + +####################################################################### +# Method for calling to Gaia-X Compliance Service +#Input: a Veriable Presentation in json format +#Output: Compliance service output +####################################################################### + + +@app.post("/compliance", tags=["Oasees testing API"]) +async def callToCompliance(body: dict): + + return callComplianceAPI(body) + + + + +####################################################################### +# Method for calling to Credential Event Service and registers serviceOffering +#Input: a compliance Veriable Presentation for Service Offering +#Output: Credential Event Service output +####################################################################### +@app.post("/credential-event-service", tags=["Oasees testing API"]) +async def callToCredentialsEventService(body: dict): + + return callCredentialsEventService(body) + + + +####################################################################### +# Method for testing Neo4j +#Input: a compacted json file +#Output: json loaded in neo4j graph database +####################################################################### +@app.post("/loadNeo4j", tags=["Oasees testing API"]) + +async def loadNeo4j(dataProductName:str,data:dict): + + return loadInNeo4j(dataProductName,data) + + + + +if __name__ == "__main__": + uvicorn.run(app, host="0.0.0.0", port=9102) + + diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/utils/__init__.py b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/utils/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/utils/connector_utils.py b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/utils/connector_utils.py new file mode 100644 index 0000000000000000000000000000000000000000..09530a3c6f532a1c6e0317da4603050e316ebd01 --- /dev/null +++ b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/utils/connector_utils.py @@ -0,0 +1,45 @@ +import json +import os + +from datamite.models.dataProductResourcesBody import DataProductResourcesModel +from fastapi import HTTPException + +from app.utils.create_asset import invoke_create_asset +from app.utils.create_policy import invoke_create_policy, checkPolicyId +from app.utils.create_contract_definition import invoke_create_contract_definition + +def load_asset_edc(body:DataProductResourcesModel, dataResouceAPi_URL:str): + + header_authorization = os.getenv("HEADER_AUTHORIZATION") + + # asset_id = asset_id.replace(os.getenv("DOMAIN_PART"),"") + # Create asset + for dataresource in body.dataResources: + formatType = body.dataAccount[0].formatType + if dataresource.dataResourceInfo is not None: + create_asset_response = invoke_create_asset(dataresource.dataResourceInfo.name, body.dataProductName, + formatType, dataresource.dataResourceInfo.description, + dataResouceAPi_URL, + header_authorization) + if not create_asset_response.ok: + raise HTTPException(status_code=400, detail=json.loads(create_asset_response.text)) + + # Create policy + policy_id = os.getenv("POLICY_ID") + contract_id = os.getenv("CONTRACT_ID") + policyExist = checkPolicyId(policy_id, header_authorization) + if not policyExist: + create_policy_response = invoke_create_policy(policy_id, header_authorization) + print (json.loads(create_policy_response.text)) + + + + create_contract_response = invoke_create_contract_definition(contract_id, policy_id, + dataresource.dataResourceInfo.name, + header_authorization) + + print(json.loads(create_contract_response.text)) + + + print (f'Asset {body.dataProductName} created') + return True diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/utils/create_asset.py b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/utils/create_asset.py new file mode 100644 index 0000000000000000000000000000000000000000..d99a3905a43b01aee9342a5ba04c808ec243d202 --- /dev/null +++ b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/utils/create_asset.py @@ -0,0 +1,50 @@ +import os +import json +import requests + + +def invoke_create_asset(dataProductId:str,dataProductName:str, dataProductFormatType:str,dataProductDescription:str,openAPI:str,header_authorization:str): + provider_host = os.getenv("PROVIDER_HOST") + provider_management_port = os.getenv("PROVIDER_MANAGEMENT_PORT") + + url = f"http://{provider_host}:{provider_management_port}/management/v3/assets" + + payload = json.dumps(generate_asset_metadata(dataProductId,dataProductName,dataProductFormatType,dataProductDescription,openAPI)) + """headers = { + 'Content-Type': 'application/json', + 'X-API-Key': header_authorization + }""" + headers = { + 'Content-Type': 'application/json' + + } + response = requests.request("POST", url, headers=headers, data=payload) + + print(f"Create asset response={response.text}") + + return response + + +def generate_asset_metadata(assetId:str,dataProductName:str,dataProductFormatType:str, dataProductDescription:str,openAPI:str): + asset_metadata = { + "@context": { + "edc": "https://w3id.org/edc/v0.0.1/ns/", + "dqv": "http://www.w3.org/ns/dqv#" + }, + "@id": assetId, + "properties": { + "name": dataProductName, + "contenttype": dataProductFormatType, + }, + "dataAddress": { + "type": "HttpData", + "name": dataProductDescription, + "baseUrl": openAPI, + "proxyQueryParams": "true", + "proxyPath": "true", + "proxyMethod": "true", + "proxyBody": "true" + } + } + + return asset_metadata diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/utils/create_contract_definition.py b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/utils/create_contract_definition.py new file mode 100644 index 0000000000000000000000000000000000000000..d431ed2fb09d854c435efd9ca090a0b1a39ccc0e --- /dev/null +++ b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/utils/create_contract_definition.py @@ -0,0 +1,82 @@ +import os +import json +import requests + + + + + +def invoke_create_contract_definition(contract_id, policy_id, asset_id,header_authorization): + provider_host = os.getenv("PROVIDER_HOST", "ekodata2.tri.lan") + provider_management_port = os.getenv("PROVIDER_MANAGEMENT_PORT", "9193") + + url = f"http://{provider_host}:{provider_management_port}/management/v2/contractdefinitions" + + payload = json.dumps(generate_contract_metadata(contract_id, policy_id, asset_id)) + """headers = { + 'Content-Type': 'application/json', + 'X-API-Key': header_authorization + }""" + headers = { + 'Content-Type': 'application/json' + } + + response = requests.request("POST", url, headers=headers, data=payload) + + print(f"Negotiate contract response={response.text}") + return response + + +def invoke_create_contract_definition_equal(contract_id, policy_id, asset_id): + provider_host = os.getenv("PROVIDER_HOST", "ekodata2.tri.lan") + provider_management_port = os.getenv("PROVIDER_MANAGEMENT_PORT", "9193") + + url = f"http://{provider_host}:{provider_management_port}/management/v2/contractdefinitions" + + payload = json.dumps(generate_contract_metadata_equal(contract_id, policy_id, asset_id)) + headers = { + 'Content-Type': 'application/json' + } + + response = requests.request("POST", url, headers=headers, data=payload) + + print(f"Negotiate contract response={response.text}") + return response + + + + +def generate_contract_metadata(contract_id, policy_id, asset_id): + contract_metadata = { + "@context": { + "edc": "https://w3id.org/edc/v0.0.1/ns/" + }, + "@id": contract_id, + "accessPolicyId": policy_id, + "contractPolicyId": policy_id, + "assetsSelector": { + "@type": "edc:Criterion", + "edc:operandLeft": "https://w3id.org/edc/v0.0.1/ns/id", + "edc:operator": "in", + "edc:operandRight": asset_id + } + } + return contract_metadata + + +def generate_contract_metadata_equal(contract_id, policy_id, asset_id): + contract_metadata = { + "@context": { + "edc": "https://w3id.org/edc/v0.0.1/ns/" + }, + "@id": contract_id, + "accessPolicyId": policy_id, + "contractPolicyId": policy_id, + "assetsSelector": { + "@type": "edc:Criterion", + "edc:operandLeft": "https://w3id.org/edc/v0.0.1/ns/id", + "edc:operator": "=", + "edc:operandRight": asset_id + } + } + return contract_metadata \ No newline at end of file diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/utils/create_policy.py b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/utils/create_policy.py new file mode 100644 index 0000000000000000000000000000000000000000..029c4215f6b00711dcdeb43a6d01a0223359d61d --- /dev/null +++ b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/app/utils/create_policy.py @@ -0,0 +1,150 @@ +import json +import os +import requests + +def checkPolicyId(policy_id,header_authorization): + provider_host = os.getenv("PROVIDER_HOST") + provider_management_port = os.getenv("PROVIDER_MANAGEMENT_PORT") + + url = f"http://{provider_host}:{provider_management_port}/management/v2/policydefinitions/request" + + + """headers = { + 'Content-Type': 'application/json', + 'X-API-Key': header_authorization + }""" + headers = { + 'Content-Type': 'application/json' + } + response = requests.request("POST", url, headers=headers) + response_json=json.loads(response.text) + for policy in response_json: + + print (policy.get("@id")) + if (policy.get("@id") == policy_id): + return True + break + + + + + +def invoke_create_policy(policy_id,header_authorization): + provider_host = os.getenv("PROVIDER_HOST", "ekodata2.tri.lan") + provider_management_port = os.getenv("PROVIDER_MANAGEMENT_PORT", "9193") + + url = f"http://{provider_host}:{provider_management_port}/management/v2/policydefinitions" + + payload = json.dumps(generate_policy_metadata_without_restrictions(policy_id)) + """headers = { + 'Content-Type': 'application/json', + 'X-API-Key': header_authorization + }""" + headers = { + 'Content-Type': 'application/json' + } + response = requests.request("POST", url, headers=headers, data=payload) + + print(f"Create policy response={response.text}") + return response + +def invoke_create_policy_time(policy_id, policy_time_interval, policy_time_interval_start_date, + policy_time_interval_end_date): + provider_host = os.getenv("PROVIDER_HOST", "ekodata2.tri.lan") + provider_management_port = os.getenv("PROVIDER_MANAGEMENT_PORT", "9193") + + url = f"http://{provider_host}:{provider_management_port}/management/v2/policydefinitions" + + payload = json.dumps(generate_policy_metadata_time(policy_id, policy_time_interval, policy_time_interval_start_date, + policy_time_interval_end_date)) + headers = { + 'Content-Type': 'application/json' + } + + response = requests.request("POST", url, headers=headers, data=payload) + + print(f"Create policy response={response.text}") + return response + +def generate_policy_metadata_time(policy_id, policy_time_interval, policy_time_interval_start_date, + policy_time_interval_end_date): + policy_metadata = { + "@context": { + "@vocab" : "https://w3id.org/edc/v0.0.1/ns/" + }, + "@id": policy_id, + "@type": "edc:PolicyDefinition", + "policy": { + "@context": "http://www.w3.org/ns/odrl.jsonld", + "@type": "Set", + "permission": [], + "prohibition": [], + "obligation": [] + } + } + if (policy_time_interval == "true") and (len(policy_time_interval_start_date) > 0) and (len(policy_time_interval_end_date) > 0): + permission_metadata = [ + { + "action": "use", + "constraint": [ + { + "@type": "AtomicConstraint", + "leftOperand": "https://w3id.org/edc/v0.0.1/ns/timeInterval", + "rightOperand": { + "@type": "xsd:date", + "@value": policy_time_interval_start_date + }, + "operator": { + "@id":"odrl:gteq" + } + }, + { + "@type": "AtomicConstraint", + "odrl:leftOperand": "https://w3id.org/edc/v0.0.1/ns/timeInterval", + "rightOperand": { + "@type": "xsd:date", + "@value": policy_time_interval_end_date + }, + "operator": { + "@id": "odrl:lteq" + } + } + ] + } + ] + policy_metadata["policy"]["permission"].append(permission_metadata) + + return policy_metadata + +def generate_policy_metadata_without_restrictions(policy_id): + policy_metadata = { + "@context": { + "@vocab" : "https://w3id.org/edc/v0.0.1/ns/" + }, + "@id": policy_id, + "@type": "edc:PolicyDefinition", + "policy": { + "@context": "http://www.w3.org/ns/odrl.jsonld", + "@type": "Set", + "permission": [], + "prohibition": [], + "obligation": [] + } + } + #edc 0.3.1 + policy_metadata = { + "@context": { + "edc": "https://w3id.org/edc/v0.0.1/ns/", + "odrl": "http://www.w3.org/ns/odrl/2/" + }, + "@id": policy_id, + "@type": "edc:PolicyDefinition", + "edc:policy": { + "@type": "odrl:Set", + "odrl:permission": [], + "odrl:prohibition": [], + "odrl:obligation": [] + } + } + + return policy_metadata diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/datamite-1.0-py2.py3-none-any.whl b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/datamite-1.0-py2.py3-none-any.whl new file mode 100644 index 0000000000000000000000000000000000000000..b943f85a9f06fc30c6815cbd47bdad8ea5ff232c Binary files /dev/null and b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/datamite-1.0-py2.py3-none-any.whl differ diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/logging.conf b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/logging.conf new file mode 100644 index 0000000000000000000000000000000000000000..b249532bf9fe092e04ae42d317dda2dc2c60583f --- /dev/null +++ b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/logging.conf @@ -0,0 +1,22 @@ +[loggers] +keys=root + + +[handlers] +keys=consoleHandler + +[formatters] +keys=simpleFormatter + +[logger_root] +level=DEBUG +handlers=consoleHandler + +[handler_consoleHandler] +class=StreamHandler +level=DEBUG +formatter=simpleFormatter +args=(sys.stdout,) + +[formatter_simpleFormatter] +format=%(asctime)s - %(name)s - %(levelname)s - %(message)s \ No newline at end of file diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/oasees.env b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/oasees.env new file mode 100644 index 0000000000000000000000000000000000000000..9e166ef303a7546d35725d13a0a2ae543d5953c3 --- /dev/null +++ b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/oasees.env @@ -0,0 +1,125 @@ +#INFO level: +#LOGGING_LEVEL=20 +# DEBUG level: +LOGGING_LEVEL=10 +DEBUG=True + + +RN_URL_END=lrn.json +TC_URL_END=tsandcs.json +PROTOCOL=https:// +FOLDER=/.well-known/ +PARTICIPANT_END=vc_participant.json +SERVICE_ACCESS_POINT=serviceAccessPoint +DATARESOURCE=dataresource +DATAPRODUCT=dataProduct +DATAPRODUCT_COMPACT=dataProduct_compact +SERVICEOFFERING=serviceOffering + + + + +FILE_END=.json +RSA_ALGO=PS256 +ISSUER_KEY= "#JWK2020-RSA" +DID=did:web: + +TERMS_AND_CONDITIONS_TEXT="The PARTICIPANT signing the Self-Description agrees as follows:\n- to update its descriptions about any changes, be it technical, organizational, or legal - especially but not limited to contractual in regards to the indicated attributes present in the descriptions.\n\nThe keypair used to sign Verifiable Credentials will be revoked where Gaia-X Association becomes aware of any inaccurate statements in regards to the claims which result in a non-compliance with the Trust Framework and policy rules defined in the Policy Rules and Labelling Document (PRLD)." + +CONTEXT_TC=https://registry.lab.gaia-x.eu/development/api/trusted-shape-registry/v1/shapes/jsonld/trustframework# + +CONTEXT_ITEM1=https://registry.lab.gaia-x.eu/development/api/trusted-shape-registry/v1/shapes/jsonld/trustframework# +CONTEXT_ITEM2=https://www.w3.org/2018/credentials/v1 +CONTEXT_ITEM3=https://w3id.org/security/suites/jws-2020/v1 + +CONTEXT_LRN=https://registry.lab.gaia-x.eu/development/api/trusted-shape-registry/v1/shapes/jsonld/participant + +NOTARIZATION_API=https://registrationnumber.notary.lab.gaia-x.eu/v1/registrationNumberVC +COMPLIANCE_API=https://compliance.lab.gaia-x.eu/v1/api/credential-offers +CREDENTIALS_EVENT_SERVICE_API=https://ces-v1.lab.gaia-x.eu/credentials-events + + +NOTARIZATION_API_DEV=https://registrationnumber.notary.lab.gaia-x.eu/development/registrationNumberVC +COMPLIANCE_API_DEV=https://compliance.lab.gaia-x.eu/development/api/credential-offers +CREDENTIALS_EVENT_SERVICE_API_DEV=https://ces-development.lab.gaia-x.eu/credentials-events + + +ISO_CODES_URL=https://iso3166-2-api.vercel.app/api/subdivision/ +VATCHECKER_API=https://ec.europa.eu/taxation_customs/vies/rest-api/ms/ + + +GAIAX_SD_FOLDER=/var/www/html/.well-known/ +NEO4J_IMPORT_FOLDER=/var/lib/neo4j/import/ + +NEO4J_IMPORT_FOLDER_LOCAL=/var/lib/neo4j/import/ +NEO4J_IMPORT_FOLDER=/var/lib/neo4j/import/ + + + +NEO4J_URI=bolt://datamite_neo4j:7687 +NEO4J_USER=neo4j +NEO4J_PASSWORD=tecnalia + + +POSTGRES_USER=postgres +POSTGRES_PASSWORD=12345 +POSTGRES_PORT=5432 +POSTGRES_HOST=datamite_postgres + + + + + +#CERTIFICATE_URL=https://datamite.digital.tecnalia.dev/.well-known/x509CertificateChain.pem +CERTIFICATE_URL=https://gaiax.oasees.digital.tecnalia.dev/.well-known/oasees.crt + + +PRIVATE_KEY="-----BEGIN PRIVATE KEY----- +MIIEvwIBADANBgkqhkiG9w0BAQEFAASCBKkwggSlAgEAAoIBAQDXHSBmv7aDvKeY +Deq1z6oR/H7RyLnT5Rcx1adFJO7yOcw87Qb7+QiOV0JY05192YUiGRowfBEFZ8YQ +hV7DajftAlzvTh7dSUp4rIhvNxud9DNbnaOi9951MM/sJ1jpEBzQPTLKUjLLt2Fr +Qyz+0SOjXS+hNYheMsU8EhZMg+E6X2M678VY7GIHXGtUhbM6DuvWfGl1FikEb4UU +b8QMN8kJkBpTEzJhDKDP3j/AkISj5HLkX8Q2Sgw8/H2DwPfyfk4gRxcXc1Y1V1J4 +HsTo26TNMqtuRhi6wCIOTROslcX/8uKuQLKQMgJ9kbtXeT4QfZ2/PltCqXjmmBJs +mzdttyM9AgMBAAECggEBANcRXNq9pAnT7S+eAmLiC6RN8LFnYTsUGXuOo90Cjw+I +b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wJBQLlluyb8DJn2GoyY7GMsEBXXxSI +I765ki7y1MVcai3vVjS91mL3pGbDfYg1r3fS0ShUKqcEu7ZE2TvtpXwOMTa12MXa +Urbz/GqWw2FUqcJLFloRodkVaA== +-----END PRIVATE KEY-----" + + + + +#EDC INFO + +#PORT=9102 + +POLICY_ID=no-restriction-policy +CONTRACT_ID=contract_no_restriction +#POLICY_TIME_INTERVAL=true +#POLICY_TIME_INTERVAL_START_DATE=2022-12-31T23:00:00.000Z +#POLICY_TIME_INTERVAL_END_DATE=2026-09-30T23:00:00.000Z + +#PROVIDER_HOST=hx2023-002.tri.lan + +PROVIDER_HOST=172.26.40.187 +#PROVIDER_HOST=oasees.tri.lan +PROVIDER_CONTROL_PORT=9192 +PROVIDER_MANAGEMENT_PORT=9193 +HEADER_AUTHORIZATION=2dSXJqNXgKAf08PINHOpwTgbcIE5tNgS diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/requirements.txt b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/requirements.txt new file mode 100644 index 0000000000000000000000000000000000000000..5699722313712a0e7c294ac61b40b9096486f3bc --- /dev/null +++ b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/gaiax-selfdescriptor-module/requirements.txt @@ -0,0 +1,13 @@ +../code/app/local_wheels/datamite-1.0-py2.py3-none-any.whl +uvicorn~=0.27.1 +fastapi~=0.109.2 +cryptography~=42.0.2 +requests~=2.31.0 +jwcrypto~=1.5.3 +PyLD~=2.0.3 +PyJWT~=2.8.0 +validators~=0.22.0 +neo4j~=5.13.0 +pydantic~=2.6.1 +pandas~=2.1.1 +orjson~=3.9.15 diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/neo4j.env b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/neo4j.env new file mode 100644 index 0000000000000000000000000000000000000000..a54ff744c5bb2448d7d93c551923363a893bb0be --- /dev/null +++ b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/neo4j.env @@ -0,0 +1,2 @@ +NEO4JLABS_PLUGINS=["apoc", "n10s"] +NEO4J_AUTH=neo4j/tecnalia diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/oasees.env b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/oasees.env new file mode 100644 index 0000000000000000000000000000000000000000..4e5f1187e7d2b6c747f32b6a6ab452506403378c --- /dev/null +++ b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/oasees.env @@ -0,0 +1,126 @@ +# INFO level: +#LOGGING_LEVEL=20 +# DEBUG level: +LOGGING_LEVEL=10 +DEBUG=True + +DEVELOPMENT=false + +RN_URL_END=lrn.json +TC_URL_END=tsandcs.json +PROTOCOL=https:// +FOLDER=/.well-known/ +PARTICIPANT_END=vc_participant.json +SERVICE_ACCESS_POINT=serviceAccessPoint +DATARESOURCE=dataresource +DATAPRODUCT=dataProduct +DATAPRODUCT_COMPACT=dataProduct_compact +SERVICEOFFERING=serviceOffering + + + + +FILE_END=.json +RSA_ALGO=PS256 +ISSUER_KEY= "#JWK2020-RSA" +DID=did:web: + +TERMS_AND_CONDITIONS_TEXT="The PARTICIPANT signing the Self-Description agrees as follows:\n- to update its descriptions about any changes, be it technical, organizational, or legal - especially but not limited to contractual in regards to the indicated attributes present in the descriptions.\n\nThe keypair used to sign Verifiable Credentials will be revoked where Gaia-X Association becomes aware of any inaccurate statements in regards to the claims which result in a non-compliance with the Trust Framework and policy rules defined in the Policy Rules and Labelling Document (PRLD)." + +CONTEXT_TC=https://registry.lab.gaia-x.eu/development/api/trusted-shape-registry/v1/shapes/jsonld/trustframework# + +CONTEXT_ITEM1=https://registry.lab.gaia-x.eu/development/api/trusted-shape-registry/v1/shapes/jsonld/trustframework# +CONTEXT_ITEM2=https://www.w3.org/2018/credentials/v1 +CONTEXT_ITEM3=https://w3id.org/security/suites/jws-2020/v1 + +CONTEXT_LRN=https://registry.lab.gaia-x.eu/development/api/trusted-shape-registry/v1/shapes/jsonld/participant + +NOTARIZATION_API=https://registrationnumber.notary.lab.gaia-x.eu/v1/registrationNumberVC +COMPLIANCE_API=https://compliance.lab.gaia-x.eu/v1/api/credential-offers +CREDENTIALS_EVENT_SERVICE_API=https://ces-v1.lab.gaia-x.eu/credentials-events + + +NOTARIZATION_API_DEV=https://registrationnumber.notary.lab.gaia-x.eu/development/registrationNumberVC +COMPLIANCE_API_DEV=https://compliance.lab.gaia-x.eu/development/api/credential-offers +CREDENTIALS_EVENT_SERVICE_API_DEV=https://ces-development.lab.gaia-x.eu/credentials-events + + +ISO_CODES_URL=https://iso3166-2-api.vercel.app/api/subdivision/ +VATCHECKER_API=https://ec.europa.eu/taxation_customs/vies/rest-api/ms/ + + +GAIAX_SD_FOLDER=/var/www/html/.well-known/ +NEO4J_IMPORT_FOLDER=/var/lib/neo4j/import/ + +NEO4J_IMPORT_FOLDER_LOCAL=/var/lib/neo4j/import/ +NEO4J_IMPORT_FOLDER=/var/lib/neo4j/import/ + + + +NEO4J_URI=bolt://oasees_neo4j:7687 +NEO4J_USER=neo4j +NEO4J_PASSWORD=tecnalia + + +POSTGRES_USER=postgres +POSTGRES_PASSWORD=12345 +POSTGRES_PORT=5432 +POSTGRES_HOST=oasees_postgres + + + + + +#CERTIFICATE_URL=https://datamite.digital.tecnalia.dev/.well-known/x509CertificateChain.pem +CERTIFICATE_URL=https://gaiax.oasees.digital.tecnalia.dev/.well-known/oasees.crt + + +PRIVATE_KEY="-----BEGIN PRIVATE KEY----- +MIIEvwIBADANBgkqhkiG9w0BAQEFAASCBKkwggSlAgEAAoIBAQDXHSBmv7aDvKeY +Deq1z6oR/H7RyLnT5Rcx1adFJO7yOcw87Qb7+QiOV0JY05192YUiGRowfBEFZ8YQ +hV7DajftAlzvTh7dSUp4rIhvNxud9DNbnaOi9951MM/sJ1jpEBzQPTLKUjLLt2Fr +Qyz+0SOjXS+hNYheMsU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YQM5r/0IQKBgQCl +5/w3FDL5WcnApq3yKfoCqi67UeoV3FFtXJrzThmQrvQd1pZwy5Zqh/kHsRkhiUkN +NBwneLyzg+Uk5OEFBWz/d7GTWj59m+e46Itt9og78TDO5weY4nP6RTH3fxT6Ntms +yTTZgk/IibxAa2JY9Gd762Q3dnQ+4r+iKjZIJjjNUQKBgQCpNJkwNE092BQ8ByA0 +zRPLAxW/ntX4QzySB4eqe0BHYRfADDw+DCwJBQLlluyb8DJn2GoyY7GMsEBXXxSI +I765ki7y1MVcai3vVjS91mL3pGbDfYg1r3fS0ShUKqcEu7ZE2TvtpXwOMTa12MXa +Urbz/GqWw2FUqcJLFloRodkVaA== +-----END PRIVATE KEY-----" + + + + +#EDC INFO + +#PORT=9102 + +POLICY_ID=no-restriction-policy +CONTRACT_ID=contract_no_restriction +#POLICY_TIME_INTERVAL=true +#POLICY_TIME_INTERVAL_START_DATE=2022-12-31T23:00:00.000Z +#POLICY_TIME_INTERVAL_END_DATE=2026-09-30T23:00:00.000Z + +#PROVIDER_HOST=hx2023-002.tri.lan + +PROVIDER_HOST=172.26.40.187 +#PROVIDER_HOST=oasees.tri.lan +PROVIDER_CONTROL_PORT=9192 +PROVIDER_MANAGEMENT_PORT=9193 +HEADER_AUTHORIZATION=2dSXJqNXgKAf08PINHOpwTgbcIE5tNgS diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/postgres.env b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/postgres.env new file mode 100644 index 0000000000000000000000000000000000000000..546be48d41e3d0d47062d67526ff0d75b8a5f67c --- /dev/null +++ b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/postgres.env @@ -0,0 +1,3 @@ +POSTGRES_USER=postgres +POSTGRES_PASSWORD=12345 +POSTGRES_DB=ces diff --git a/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/sql/create_tables.sql b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/sql/create_tables.sql new file mode 100644 index 0000000000000000000000000000000000000000..21854532da24d3246b55a51d1baf110c33bd5f21 --- /dev/null +++ b/GAIAX_DATAPRODUCT_OASEES_DOCKER_COMPOSE/sql/create_tables.sql @@ -0,0 +1,6 @@ +CREATE TABLE public.ces ( + ces_id varchar(250) NOT NULL, + dataProduct_json json NULL, + compliance_json json NULL, + CONSTRAINT workflow_store_pkey PRIMARY KEY (ces_id) +);