Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found

Target

Select target project
  • eclipse/xfsc/ocm/ocm-engine
  • zdravko61/ocm-engine
  • mjuergenscg/ocm-engine
  • tsabolov/ocm-engine
  • mikesell/ocm-engine
5 results
Show changes
Commits on Source (391)
Showing
with 340 additions and 2473 deletions
......@@ -3,6 +3,7 @@
# Except these files
!*.ts
!*.mts
!*.d.ts
# .. also in subdirectories
......
......@@ -14,13 +14,13 @@ module.exports = {
project: ['./tsconfig.eslint.json'],
},
settings: {
'import/extensions': ['.js', '.ts'],
'import/extensions': ['.js', '.mjs', '.ts', '.mts'],
'import/parsers': {
'@typescript-eslint/parser': ['.ts', '.tsx'],
'@typescript-eslint/parser': ['.ts', '.tsx', '.mts'],
},
'import/resolver': {
typescript: {
project: 'packages/*/tsconfig.json',
project: ['apps/*/tsconfig.json'],
alwaysTryTypes: true,
},
},
......@@ -75,7 +75,7 @@ module.exports = {
},
overrides: [
{
files: ['*.spec.ts', '*.e2e-spec.ts', '**/tests/**'],
files: ['*.spec.ts', '*.e2e-spec.ts', '**/tests/**', '**/test/**'],
env: {
jest: true,
node: true,
......@@ -88,6 +88,6 @@ module.exports = {
},
],
},
},
}
],
};
include:
- project: 'eclipse/xfsc/dev-ops/ci-templates'
file: 'helm-build-ci.yaml'
ref: main
- project: 'eclipsefdn/it/releng/gitlab-runner-service/gitlab-ci-templates'
file: '/jobs/buildkit.gitlab-ci.yml'
stages:
- build
- release
docker-build:
extends: .buildkit
parallel:
matrix:
- SERVICE: [connection-manager, credential-manager,did-manager,proof-manager,ssi-abstraction,schema-manager,tenant-manager]
stage: build
variables:
CI_REGISTRY: ${HARBOR_HOST}
CI_REGISTRY_USER: ${HARBOR_USERNAME}
CI_REGISTRY_PASSWORD: ${HARBOR_PASSWORD}
CI_REGISTRY_IMAGE: ${HARBOR_HOST}/${HARBOR_PROJECT}/$SERVICE
BUILD_ARG: "--opt build-arg:SERVICE=${SERVICE}"
......@@ -4,7 +4,9 @@
# Except for these files
!*.ts
!*.d.ts
!*.mts
!jest.config.js
!*.json
# .. also in subdirectories
!*/
......@@ -17,6 +19,3 @@ node_modules
apps/**/dist
compose
documentation
# Ignore ssi-abstraction for now
apps/ssi-abstraction
# Base
FROM node:20 AS base
FROM node:20.11 AS dependencies
ARG APP_HOME=/home/node/app
ARG SERVICE
WORKDIR /home/node/app
RUN corepack enable
COPY package.json pnpm-lock.yaml pnpm-workspace.yaml tsconfig*.json .swcrc ./
COPY patches ./patches
COPY apps/shared/package.json ./apps/shared/
RUN pnpm install --frozen-lockfile
# Build shared
FROM node:20.11 as build-shared
ARG APP_HOME=/home/node/app
ARG SERVICE
......@@ -8,65 +21,47 @@ WORKDIR ${APP_HOME}
RUN corepack enable
# # libindy build
# FROM node:20-bullseye AS ssi-base
# RUN apt-get update \
# && apt-get install -y --no-install-recommends libsodium-dev libzmq3-dev
# RUN curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y --default-toolchain '1.58.0'
# RUN git clone https://github.com/hyperledger/indy-sdk
# RUN cd indy-sdk/libindy && ~/.cargo/bin/cargo build --release
# RUN cd indy-sdk/libindy && mv target/release/libindy.so /usr/lib/libindy.so
COPY apps/shared ./apps/shared
COPY --from=dependencies /home/node/app/package.json /home/node/app/pnpm-lock.yaml /home/node/app/pnpm-workspace.yaml /home/node/app/tsconfig*.json /home/node/app/.swcrc ./
COPY --from=dependencies /home/node/app/node_modules ./node_modules
COPY --from=dependencies /home/node/app/apps/shared/node_modules ./apps/shared/node_modules
COPY --from=dependencies /home/node/app/patches ./patches
RUN pnpm --filter shared build
# Build
FROM base AS build
# Build service
FROM node:20.11 AS build-service
ARG APP_HOME=/home/node/app
WORKDIR ${APP_HOME}
ARG SERVICE
COPY package.json pnpm-lock.yaml pnpm-workspace.yaml tsconfig*.json .swcrc ./
COPY apps/${SERVICE}/package.json ./apps/${SERVICE}/
COPY apps/shared/package.json ./apps/shared/
WORKDIR ${APP_HOME}
RUN pnpm install --frozen-lockfile
RUN corepack enable
COPY --from=dependencies /home/node/app/package.json /home/node/app/pnpm-lock.yaml /home/node/app/pnpm-workspace.yaml /home/node/app/tsconfig*.json /home/node/app/.swcrc ./
COPY --from=dependencies /home/node/app/node_modules ./node_modules
COPY --from=dependencies /home/node/app/patches ./patches
COPY --from=build-shared /home/node/app/apps/shared ./apps/shared
COPY apps/${SERVICE} ./apps/${SERVICE}
COPY apps/shared ./apps/shared
RUN pnpm --filter shared build
RUN pnpm --filter ${SERVICE} build:production
RUN pnpm --filter ${SERVICE} --prod deploy build
RUN pnpm --filter shared --prod deploy shared
# This is a way of keeping the generated prisma client in the build folder
RUN if [ -d ./apps/${SERVICE}/node_modules/\@prisma/client ]; then \
GLOBAL_PRISMA_SETUP=`realpath ./apps/${SERVICE}/node_modules/\@prisma/client` \
GLOBAL_PRISMA_CLIENT=`readlink -f ${GLOBAL_PRISMA_SETUP}/../../.prisma` \
BUILD_PRISMA_SETUP=`realpath ./build/node_modules/\@prisma/client` \
BUILD_PRISMA_CLIENT=`readlink -f ${BUILD_PRISMA_SETUP}/../..` \
sh -c 'cp -r $GLOBAL_PRISMA_CLIENT $BUILD_PRISMA_CLIENT'; \
fi
RUN pnpm install --frozen-lockfile && pnpm --filter ${SERVICE} build && pnpm --filter ${SERVICE} --prod deploy build
# Final
FROM node:20 AS final
FROM node:20.11-slim AS final
ARG APP_HOME=/home/node/app
ARG NODE_ENV=production
ENV NODE_ENV=${NODE_ENV}
WORKDIR ${APP_HOME}
ENTRYPOINT ["./docker-entrypoint.sh"]
WORKDIR /home/node/app
CMD ["node", "dist/main.js"]
COPY --chown=node:node ./docker-entrypoint.sh ./docker-entrypoint.sh
COPY --from=build --chown=node:node ${APP_HOME}/build/dist ./dist
COPY --from=build --chown=node:node ${APP_HOME}/shared/dist ./shared
COPY --from=build --chown=node:node ${APP_HOME}/build/node_modules ./node_modules
COPY --from=build --chown=node:node ${APP_HOME}/build/package.json .
COPY --from=build-service --chown=node:node /home/node/app/build/dist ./dist
COPY --from=build-service --chown=node:node /home/node/app/build/node_modules ./node_modules
COPY --from=build-service --chown=node:node /home/node/app/build/package.json .
# Cut unnecessary stuff from package.json. Only leave name, version and module type
# Cut unnecessary stuff from package.json. Only leave name, version, description and module type
RUN node -e "\
const { name, version, type } = JSON.parse(fs.readFileSync('./package.json', 'utf-8'));\
fs.writeFileSync('./package.json', JSON.stringify({ name, version, type }, null, 2));\
const { name, description, version, type } = JSON.parse(fs.readFileSync('./package.json', 'utf-8'));\
fs.writeFileSync('./package.json', JSON.stringify({ name, version, description, type }, null, 2));\
"
# USER node
USER node
Organizational Credential Manager
The Organisation Credential Manager service establishes trust between
the different participants within the decentralized ecosystem. It includes
all trust-related functions required to manage Verifiable Credentials.
Copyright 2022 Vereign AG
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
This incorporates
"elastic/ecs-winston-format"
, a Node.js package to provide a formatter for the winston logger compatible
with Elastic Common Schema (ECS) logging, which is covered by the following copyright
and permission notice:
Copyright 2020 Elastic and contributors
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
This also incorporates
"nestjs"
, a progressive Node.js framework for building efficient and scalable server-side applications,
which is covered by the following copyright and permission notice:
Copyright (c) 2017-2022 Kamil Mysliwiec <https://kamilmysliwiec.com>
(The MIT License)
Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
'Software'), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:
The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
This also incorporates
"nestjs/terminus"
, integrated healthchecks for Nest, which contains the
following copyright and permission notice:
Copyright (c) 2018-2021 Livio Brunner, Kamil Myśliwiec
(The MIT License)
Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
'Software'), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:
The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
This also incorporates
"prisma client"
, an auto-generated query builder that enables type-safe database access and reduces
boilerplate, which is covered by the following copyright and permission notice:
Copyright 2019 Johannes Schickling
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
This also incorporates
"types/node"
, type definitions for Node, which is covered by the following copyright and
permission notice:
Copyright Microsoft TypeScript, DefinitelyTyped, Alberto Schiabel,
Alvis HT Tang, Andrew Makarov, Benjamin Toueg, Chigozirim C., David Junger, Deividas Bakanas, Eugene Y. Q. Shen,
Hannes Magnusson, Huw, Kelvin Jin, Klaus Meinhardt, Lishude, Mariusz Wiktorczyk, Mohsen Azimi, Nicolas Even,
Nikita Galkin, Parambir Singh, Sebastian Silbermann, Simon Schick, Thomas den Hollander, Wilco Bakker, wwwy3y3,
Samuel Ainsworth, Kyle Uehlein, Thanik Bhongbhibhat, Marcin Kopacz, Trivikram Kamat, Junxiao Shi, Ilia Baryshnikov,
ExE Boss, Piotr Błażejewicz, Anna Henningsen, Victor Perin, Yongsheng Zhang, NodeJS Contributors,
Linus Unnebäck, wafuwafu13, and Matteo Collina.
(The MIT License)
Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
'Software'), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:
The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
This also incorporates
"class-validator"
, a tool to allow decorator and non-decorator based validation,
Copyright 2015-2020 TypeStack
(The MIT License)
Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
'Software'), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:
The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
This also incorporates
"express"
, a fast, unopinionated, minimalist web framework for node, which is covered by the following copyright
and permission notice:
Copyright (c) 2009-2014 TJ Holowaychuk <tj@vision-media.ca>
Copyright (c) 2013-2014 Roman Shtylman <shtylman+expressjs@gmail.com>
Copyright (c) 2014-2015 Douglas Christopher Wilson <doug@somethingdoug.com>
(The MIT License)
Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
'Software'), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:
The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
This also incorporates
"joi"
, the most powerful schema description language and data validator for JavaScript, which is
covered by the following copyright and permission notice:
Copyright (c) 2012-2020, Sideway. Inc, and project contributors.
Copyright (c) 2012-2014, Walmart.
All rights reserved.
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
- Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
- Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or
other materials provided with the distribution.
- The names of any contributors may not be used to endorse or promote products derived from this software without
specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDERS AND CONTRIBUTORS
BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
This also incorporates
"moment"
, a JavaScript date library for parsing, validating, manipulating, and formatting dates,
which is covered by the following copyright and permission notice:
Copyright (c) JS Foundation and other contributors
(The MIT License)
Permission is hereby granted, free of charge, to any person
obtaining a copy of this software and associated documentation
files (the "Software"), to deal in the Software without
restriction, including without limitation the rights to use,
copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following
conditions:
The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
OTHER DEALINGS IN THE SOFTWARE.
This also incorporates
"nats"
, a Node.js client for the NATS messaging system, which is covered by
the following copyright and permission notice:
Copyright 2013-2018 The NATS Authors
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
This also incorporates
"prisma"
, next-generation ORM for Node.js & TypeScript | PostgreSQL, MySQL, MariaDB, SQL Server,
SQLite, MongoDB and CockroachDB, which is covered by the following copyright and
permission notice:
Copyright 2019 Johannes Schickling
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
1. Definitions.
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product 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 NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of 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 reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
boilerplate notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
file or class name and description of purpose be included on the
same "printed page" as the copyright notice for easier
identification within third-party archives.
Copyright 2024 Gaia-X
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
This also incorporates
"reflect-metadata"
, prototype for a Metadata Reflection API for ECMAScript, which is covered
by the following copyright and permission notice:
Copyright 2019 Ron Buckton
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
This also incorporates
"rxjs"
, reactive extensions for JavaScript, which is covered by the following copyright
and permission notice:
Copyright (c) 2015-2018 Google, Inc., Netflix, Inc., Microsoft Corp. and contributors
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
This also incorporates
"winston"
, a logger for just about everything, which is covered by the following copyright and
permission notice:
Copyright (c) 2010 Charlie Robbins
(The MIT License)
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
This also incorporates
"winston-elasticsearch"
, an elasticsearch transport for winston, which is covered by the following copyright and
permission notice:
Copyright (c) 2015 - 2018 Thomas Hoppe.
Copyright (c) 2013 Jacques-Olivier D. Bernier.
(The MIT License)
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
# ocm-engine version 1
# Organization Credential Manager (OCM)
#### Dependencies
## Introduction
Node 12
Python 2.5.0 >= <3.0.0
pnpm
Organization Credential Manager (OCM) is a comprehensive suite of microservices designed to facilitate the management of digital credentials within an organizational context. Utilizing the principles of Self-Sovereign Identity (SSI), OCM leverages a series of components to enable secure, efficient handling of credentials, keys, and connections between entities.
### Setup local
## Components
1. pnpm install
2. pnpm prisma:generate
3. pnpm /app/:build
OCM is comprised of several key microservices, each serving a specific role within the credential management ecosystem:
app options: attestation, connection, principal, ssi
### [SSI Abstraction](apps/ssi-abstraction/README.md)
A wrapper around the Credo library ([Credo](https://credo.js.org)), formerly known as Aries Framework Javascript, an implementation of a Hyperledger Indy Agent in TypeScript. This service abstracts the complexities of SSI operations for other components.
### Docker compose
### [Tenant Manager](apps/tenant-manager/README.md)
Manages the creation and listing of OCM tenants, with each tenant maintaining their collections of credentials, keys, etc. This service acts as a critical interface to the SSI Abstraction functionality and is intended for administrative use only.
1. Go to compose dir
### [DID Manager](apps/did-manager/README.md)
Provides API functions for registering Decentralized Identifiers (DIDs) on the Indy Ledger and resolving existing DID Documents, facilitating secure identity verification and management.
2. docker-compose up
### [Connection Manager](apps/connection-manager/README.md)
Facilitates the establishment of connections between OCM tenants using Aries protocols, enabling secure, verified interactions.
## Example Flows (OCM Usage)
### [Schema Manager](apps/schema-manager/README.md)
Allows tenants to manage Indy Schemas and Credential Definitions, laying the groundwork for the creation and recognition of standardized credential formats.
Please refer to [OCM-flow-overview](documentation/ocm-flow-overview.md)
### [Credential Manager](apps/credential-manager/README.md)
Offers an API for the detailed management of tenant credentials, streamlining the process of issuing, holding, and verifying digital credentials.
### [Proof Manager](apps/proof-manager/README.md)
Enables tenants to create proof requests, an essential feature for the verification of credential authenticity and integrity.
## Deployment
### Kubernetes
OCM can be deployed within a Kubernetes cluster to leverage the benefits of container orchestration for managing and scaling the microservices efficiently. The deployment process is streamlined through the use of Helm, a package manager for Kubernetes that facilitates the installation, upgrade, and management of Kubernetes applications.
Each microservice within OCM is equipped with its own Helm chart located in the service's folder. These Helm charts define the Kubernetes resources required for deploying and running the service, including Deployments, Services, and any necessary ConfigMaps or Secrets.
### Docker Compose (Local)
For local development and testing purposes, the OCM stack can also be run using Docker Compose with the following command:
```bash
docker compose up -d
```
This command builds the service container images and starts the stack. It's a convenient way to quickly bring up the OCM environment on a local machine for development, testing, or demonstration purposes.
#### Starting multiple instances of OCM
To demonstrate
```bash
./scripts/start_instance.sh
```
> This command can be run multiple times to start several instances of OCM.
> To stop instances that were started using the above command, use `./scripts/stop_instance.sh`.
## Local Development
To run each service locally, the following prerequisites are needed:
- Node.js (installed on the local machine)
- pnpm (package manager)
- Docker Compose (for running NATS server and S3 storage)
Before starting a service, create a `.env` file in the service's directory based on the `.env.example` provided, renaming it to `.env`.
## Documentation and Example Flows
For detailed usage and example flows, please refer to the [Postman Collection](documentation/Gaia-X_Organization_Credential_Manager.postman_collection.json) and the [OCM Example Flows](documentation/ocm-example-flows.md).
## Security
Note: Authentication and Authorization mechanisms are considered outside the scope of this project and should be addressed at the infrastructure level or through other means.
## License
Licensed under the Apache 2.0 License ([LICENSE](LICENSE)).
PORT=3005
DATABASE_URL=postgresql://root:password@localhost:5432/postgres?schema=attestation
ECSURL=http://localhost:9200/
ACCEPT_MEMBERSHIP_CREDENTIALS_CONFIG = AUTO
NATS_URL=nats://localhost:4222
AGENT_URL=http://localhost:3010
TSA_URL=https://gaiax.vereign.com/tsa/policy/policy/example
USE_AUTH=false
OAUTH_CLIENT_ID=clientid
OAUTH_CLIENT_SECRET=clientsecret
OAUTH_TOKEN_URL=https://tokenurl
\ No newline at end of file
# GDPR Compliance Document
The objective of this document is to detail, the data being stored and proccessed by the Organization Credential Manager's, Attestation Manger.
## What information is stored
### Source User Information
The Open Id connect claims that MAY contain all sorts of personal data (like email, name, age and others), are received from any external source.
### Technical User Information (Public)
- Schema information (public)
- Credential/credential definition ids and states
- DID of issuer
- DID of holder
- Created/updated dates
- Offered credential attributes and attachments
## How is the information stored
### Source User Information
Source User Information is encrypted using the Private Key of the Organizations SSI Agent and stored until the issuance of credential in Organization's SSI Agent's PostgreSQL database.
### Technical User Information (Public)
Technical User Information is encrypted using the Private Key of the Organizations SSI Agent and stored internally (on the agent) on PostgreSQL and externally/ metadata (shared between the OCM services) on PostgreSQL of Organization.
## Who can access the information
The Source User Information and Technical User Information both are accessible only by the Organization specific SSI agent's private key.
## How long will the information stay
### Source User Information
The Source User Information is wiped out once the credential is issued.
### Technical User Information (Public)
The Technical User Information is wiped out according to the retention periods (not defined yet).
{
"info": {
"_postman_id": "096d259a-3afa-45e2-b8fd-ce78cc1afaee",
"name": "Gaia-x Attestation Manager API",
"description": "API documentation for GAIA-X Attestation Manager",
"schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json",
"_exporter_id": "10250261"
},
"item": [
{
"name": "Fetch credential information by credential id",
"request": {
"method": "GET",
"header": [
{
"key": "Accept",
"value": "application/json"
}
],
"url": {
"raw": "{{baseUrl}}/v1/credential-info/:id",
"host": ["{{baseUrl}}"],
"path": ["v1", "credential-info", ":id"],
"variable": [
{
"key": "id"
}
]
}
},
"response": []
},
{
"name": "Send credential proposal to connection",
"request": {
"method": "POST",
"header": [
{
"key": "Content-Type",
"value": "application/json"
},
{
"key": "Accept",
"value": "application/json"
}
],
"body": {
"mode": "raw",
"raw": "{\n \"connectionId\": \"<string>\",\n \"credentialDefinitionId\": \"<string>\",\n \"comment\": \"<string>\",\n \"credentialProposal\": {},\n \"autoAcceptCredential\": \"<string>\"\n}",
"options": {
"raw": {
"headerFamily": "json",
"language": "json"
}
}
},
"url": {
"raw": "{{baseUrl}}/v1/create-propose-credential",
"host": ["{{baseUrl}}"],
"path": ["v1", "create-propose-credential"]
}
},
"response": []
},
{
"name": "Send credential offer with credential values to connection",
"request": {
"method": "POST",
"header": [
{
"key": "Content-Type",
"value": "application/json"
},
{
"key": "Accept",
"value": "application/json"
}
],
"body": {
"mode": "raw",
"raw": "{\n \"connectionId\": \"<string>\",\n \"credentialDefinitionId\": \"<string>\",\n \"comment\": \"<string>\",\n \"attributes\": [\n {\n \"name\": \"<string>\",\n \"value\": \"<string>\"\n },\n {\n \"name\": \"<string>\",\n \"value\": \"<string>\"\n }\n ],\n \"autoAcceptCredential\": \"<string>\"\n}",
"options": {
"raw": {
"headerFamily": "json",
"language": "json"
}
}
},
"url": {
"raw": "{{baseUrl}}/v1/create-offer-credential",
"host": ["{{baseUrl}}"],
"path": ["v1", "create-offer-credential"]
}
},
"response": []
},
{
"name": "Accept credential request by credential id",
"request": {
"method": "POST",
"header": [],
"url": {
"raw": "{{baseUrl}}/v1/accept-request/:credentialId",
"host": ["{{baseUrl}}"],
"path": ["v1", "accept-request", ":credentialId"],
"variable": [
{
"key": "credentialId"
}
]
}
},
"response": []
},
{
"name": "Accept credential proposal by credential id",
"request": {
"method": "POST",
"header": [],
"url": {
"raw": "{{baseUrl}}/v1/accept-proposal/:credentialId",
"host": ["{{baseUrl}}"],
"path": ["v1", "accept-proposal", ":credentialId"],
"variable": [
{
"key": "credentialId"
}
]
}
},
"response": []
},
{
"name": "Accept credential offer by credential id",
"request": {
"method": "POST",
"header": [],
"url": {
"raw": "{{baseUrl}}/v1/accept-offer/:credentialId",
"host": ["{{baseUrl}}"],
"path": ["v1", "accept-offer", ":credentialId"],
"variable": [
{
"key": "credentialId"
}
]
}
},
"response": []
},
{
"name": "Accept credentials by credential id",
"request": {
"method": "POST",
"header": [],
"url": {
"raw": "{{baseUrl}}/v1/accept-credential/:credentialId",
"host": ["{{baseUrl}}"],
"path": ["v1", "accept-credential", ":credentialId"],
"variable": [
{
"key": "credentialId"
}
]
}
},
"response": []
},
{
"name": "Fetch list of credential definition",
"request": {
"method": "GET",
"header": [
{
"key": "Accept",
"value": "application/json"
}
],
"url": {
"raw": "{{baseUrl}}/v1/credentialDef",
"host": ["{{baseUrl}}"],
"path": ["v1", "credentialDef"]
}
},
"response": []
},
{
"name": "Fetch credential definition by id",
"request": {
"method": "GET",
"header": [
{
"key": "Accept",
"value": "application/json"
}
],
"url": {
"raw": "{{baseUrl}}/v1/credentialDef/:id",
"host": ["{{baseUrl}}"],
"path": ["v1", "credentialDef", ":id"],
"variable": [
{
"key": "id",
"value": "<string>"
}
]
}
},
"response": []
},
{
"name": "Create new credential definition",
"request": {
"method": "POST",
"header": [
{
"key": "Content-Type",
"value": "application/json"
},
{
"key": "Accept",
"value": "application/json"
}
],
"body": {
"mode": "raw",
"raw": "{\n \"schemaID\": \"<string>\",\n \"name\": \"<string>\",\n \"isRevokable\": \"<boolean>\",\n \"isAutoIssue\": \"<boolean>\",\n \"expiryHours\": \"<string>\",\n \"createdBy\": \"<string>\",\n \"type\": \"<string>\"\n}",
"options": {
"raw": {
"headerFamily": "json",
"language": "json"
}
}
},
"url": {
"raw": "{{baseUrl}}/v1/credentialDef",
"host": ["{{baseUrl}}"],
"path": ["v1", "credentialDef"]
}
},
"response": []
},
{
"name": "Fetch list of credentials using pagination and queries",
"request": {
"method": "GET",
"header": [
{
"key": "Accept",
"value": "application/json"
}
],
"url": {
"raw": "{{baseUrl}}/v1/credential?page=0&pageSize=10&isReceived&threadId&state&credDefId&createdDateStart&createdDateEnd&updatedDateStart&updatedDateEnd&expirationDateStart&expirationDateEnd&connectionId&principalDid",
"host": ["{{baseUrl}}"],
"path": ["v1", "credential"],
"query": [
{
"key": "page",
"value": "0"
},
{
"key": "pageSize",
"value": "10"
},
{
"key": "isReceived",
"value": null
},
{
"key": "threadId",
"value": null
},
{
"key": "state",
"value": null
},
{
"key": "credDefId",
"value": null
},
{
"key": "createdDateStart",
"value": null
},
{
"key": "createdDateEnd",
"value": null
},
{
"key": "updatedDateStart",
"value": null
},
{
"key": "updatedDateEnd",
"value": null
},
{
"key": "expirationDateStart",
"value": null
},
{
"key": "expirationDateEnd",
"value": null
},
{
"key": "connectionId",
"value": null
},
{
"key": "principalDid",
"value": null
}
]
}
},
"response": [
{
"name": "Fetch list of credentials using pagination and queries",
"originalRequest": {
"method": "GET",
"header": [
{
"key": "Accept",
"value": "application/json"
}
],
"url": {
"raw": "{{baseUrl}}/v1/credential?page=0&pageSize=10&isReceived&threadId&state&credDefId&createdDateStart&createdDateEnd&updatedDateStart&updatedDateEnd&expirationDateStart&expirationDateEnd&connectionId&principalDid",
"host": ["{{baseUrl}}"],
"path": ["v1", "credential"],
"query": [
{
"key": "page",
"value": "0"
},
{
"key": "pageSize",
"value": "10"
},
{
"key": "isReceived",
"value": null
},
{
"key": "threadId",
"value": null
},
{
"key": "state",
"value": null
},
{
"key": "credDefId",
"value": null
},
{
"key": "createdDateStart",
"value": null
},
{
"key": "createdDateEnd",
"value": null
},
{
"key": "updatedDateStart",
"value": null
},
{
"key": "updatedDateEnd",
"value": null
},
{
"key": "expirationDateStart",
"value": null
},
{
"key": "expirationDateEnd",
"value": null
},
{
"key": "connectionId",
"value": null
},
{
"key": "principalDid",
"value": null
}
]
}
},
"status": "OK",
"code": 200,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Date",
"value": "Fri, 02 Jun 2023 05:58:26 GMT"
},
{
"key": "Content-Type",
"value": "application/json; charset=utf-8"
},
{
"key": "Content-Length",
"value": "4576"
},
{
"key": "Connection",
"value": "keep-alive"
},
{
"key": "X-Powered-By",
"value": "Express"
},
{
"key": "Access-Control-Allow-Origin",
"value": "*"
},
{
"key": "ETag",
"value": "W/\"11e0-n29HDRxi/1rhzktri7nD+uBh93Y\""
},
{
"key": "Strict-Transport-Security",
"value": "max-age=15724800; includeSubDomains"
}
],
"cookie": [],
"body": "{\n \"statusCode\": 200,\n \"message\": \"Credential fetch successfully\",\n \"data\": {\n \"count\": 87,\n \"records\": [\n {\n \"id\": \"01b3d49c-1d51-4070-924d-9424ea239a93\",\n \"credentialId\": \"f4472554-ee2e-4262-bfc6-0ed268c8be31\",\n \"credDefId\": \"BsfUfTECZPVRnoCgHUfB3p:3:CL:48687:Automation_CredDef_001\",\n \"threadId\": \"cdb2ce40-970d-4bb2-9d8b-a4aa5e517226\",\n \"state\": \"done\",\n \"principalDid\": \"CuZ94QvJCHihuCBCzRULoc\",\n \"connectionId\": \"2ded97e4-0c8e-470a-8e53-481e24e50db7\",\n \"createdDate\": \"2023-05-15T13:10:52.070Z\",\n \"updatedDate\": \"2023-05-15T13:13:10.164Z\",\n \"expirationDate\": \"2023-05-16T13:10:52.068Z\"\n },\n {\n \"id\": \"0306d10d-1b8f-471a-98c2-86edfe24e1dd\",\n \"credentialId\": \"c1b80b87-e044-4056-87ed-f53b50480015\",\n \"credDefId\": \"BsfUfTECZPVRnoCgHUfB3p:3:CL:46833:OCM1-passport\",\n \"threadId\": \"52d63479-a20e-47e3-9e5b-43b06998566d\",\n \"state\": \"offer-sent\",\n \"principalDid\": \"FyydY9n2QZyuskXGm73kH8\",\n \"connectionId\": \"f468aeaa-6482-44af-b3d5-eb67aed0a2bd\",\n \"createdDate\": \"2023-05-09T12:52:55.259Z\",\n \"updatedDate\": \"2023-05-09T12:52:55.259Z\",\n \"expirationDate\": null\n },\n {\n \"id\": \"0b444def-2419-4635-97a5-46b8a2a93a8c\",\n \"credentialId\": \"2b7f4387-3361-4bc5-b4f8-0a6a3fb7b05a\",\n \"credDefId\": \"BsfUfTECZPVRnoCgHUfB3p:3:CL:48362:Enrollment_credDef-222222322211\",\n \"threadId\": \"84336905-fbdb-4405-be94-24f0bb3143d8\",\n \"state\": \"done\",\n \"principalDid\": \"9M5aDzwUzeiq3sSwBD5mPC\",\n \"connectionId\": \"4a1b0ed2-d7ce-4629-9d91-03247f0015ca\",\n \"createdDate\": \"2023-05-09T14:06:00.663Z\",\n \"updatedDate\": \"2023-05-09T14:09:38.440Z\",\n \"expirationDate\": \"2023-05-10T14:06:00.661Z\"\n },\n {\n \"id\": \"0be85272-0802-48c4-a155-787534b050c7\",\n \"credentialId\": \"85ec488c-2f23-4544-885e-3f0e9a4f3e63\",\n \"credDefId\": \"48f6D93QZPA127oknMazWy:3:CL:41034:test2-credDef\",\n \"threadId\": \"edbdddc1-1a49-4d3e-aa47-bfbdca65aedf\",\n \"state\": \"offer-sent\",\n \"principalDid\": \"LpN6wLLjfm5p1tqUo8Nf3w\",\n \"connectionId\": \"d45614da-c174-4399-bf27-3cf01928fe3a\",\n \"createdDate\": \"2023-03-27T12:10:22.645Z\",\n \"updatedDate\": \"2023-03-27T12:10:22.645Z\",\n \"expirationDate\": \"2023-03-28T11:10:22.642Z\"\n },\n {\n \"id\": \"13424638-ce33-4c77-9375-7b24e2d55e10\",\n \"credentialId\": \"4fea6609-cb4f-478b-9c30-a1ef09453dd1\",\n \"credDefId\": \"BsfUfTECZPVRnoCgHUfB3p:3:CL:50014:LoginCredentials2\",\n \"threadId\": \"eeb6a119-68bd-40bf-b454-69cd0dd6c13d\",\n \"state\": \"done\",\n \"principalDid\": \"7tziR5BbxSbqJbrtDC7ZJw\",\n \"connectionId\": \"9d6b7000-5f5a-49cd-91e7-6aff9ef73f83\",\n \"createdDate\": \"2023-05-22T11:23:47.206Z\",\n \"updatedDate\": \"2023-05-22T11:24:05.454Z\",\n \"expirationDate\": null\n },\n {\n \"id\": \"14b85bde-d2f4-4e1a-a49c-b7f51e0b9d68\",\n \"credentialId\": \"7dbd2d9d-b285-4c8d-a8c0-c982dbb76194\",\n \"credDefId\": \"48f6D93QZPA127oknMazWy:3:CL:41034:test2-credDef\",\n \"threadId\": \"34c43f2b-5223-42ac-8d6b-d6aa3508b30e\",\n \"state\": \"offer-sent\",\n \"principalDid\": \"LpN6wLLjfm5p1tqUo8Nf3w\",\n \"connectionId\": \"d45614da-c174-4399-bf27-3cf01928fe3a\",\n \"createdDate\": \"2023-03-27T11:43:12.367Z\",\n \"updatedDate\": \"2023-03-27T11:43:12.367Z\",\n \"expirationDate\": \"2023-03-28T10:43:12.364Z\"\n },\n {\n \"id\": \"15281264-9b75-457b-babf-ea453ef742df\",\n \"credentialId\": \"c597ebb2-9dea-4a75-9616-1cf577818699\",\n \"credDefId\": \"48f6D93QZPA127oknMazWy:3:CL:42130:Driver Licence\",\n \"threadId\": \"48866e07-61b7-4036-9aeb-b4048edb1f5c\",\n \"state\": \"done\",\n \"principalDid\": \"AZGMhjPLkTHmHrwbaVCg8S\",\n \"connectionId\": \"1e55ac60-ce30-4887-b51b-ce581ab020c0\",\n \"createdDate\": \"2023-03-22T07:44:10.338Z\",\n \"updatedDate\": \"2023-03-22T07:45:48.314Z\",\n \"expirationDate\": null\n },\n {\n \"id\": \"17713cae-bbb5-4347-ab56-bb0abd11d4e3\",\n \"credentialId\": \"404433ba-bf23-4a1b-91b9-4c2e0b550811\",\n \"credDefId\": \"PFoX6wEKUmUrciXad7gyxQ:3:CL:46833:SSI-prod-passport1\",\n \"threadId\": \"3ad48da9-536d-4a70-b519-4a96328fff68\",\n \"state\": \"credential-received\",\n \"principalDid\": \"FyydY9n2QZyuskXGm73kH8\",\n \"connectionId\": \"f468aeaa-6482-44af-b3d5-eb67aed0a2bd\",\n \"createdDate\": \"2023-05-09T13:21:04.464Z\",\n \"updatedDate\": \"2023-05-09T13:21:59.765Z\",\n \"expirationDate\": null\n },\n {\n \"id\": \"17fe1bd6-1fb8-441d-bab7-da0c065feade\",\n \"credentialId\": \"fb713703-4dbb-4046-92a9-38275dfdc3c3\",\n \"credDefId\": \"BsfUfTECZPVRnoCgHUfB3p:3:CL:48710:Automation_CredDef_001\",\n \"threadId\": \"92d75b0f-658a-4a15-ad8d-464e1bc9ed56\",\n \"state\": \"done\",\n \"principalDid\": \"CuZ94QvJCHihuCBCzRULoc\",\n \"connectionId\": \"2ded97e4-0c8e-470a-8e53-481e24e50db7\",\n \"createdDate\": \"2023-05-15T13:10:49.447Z\",\n \"updatedDate\": \"2023-05-15T13:14:28.548Z\",\n \"expirationDate\": \"2023-05-16T13:10:49.445Z\"\n },\n {\n \"id\": \"1879df35-ccaf-444a-b953-10339531582a\",\n \"credentialId\": \"9a5a8b7b-f1d7-45a3-a5f4-af78d0b450f3\",\n \"credDefId\": \"2ZDQuDB9Ww23qnesQLw9aq:3:CL:43799:Enrollment_credDef-22222322211\",\n \"threadId\": \"4ab8c6a6-7183-41db-bc5c-75d31c5c3753\",\n \"state\": \"offer-sent\",\n \"principalDid\": \"9aRgDXK7SXJVKpbp91yAmr\",\n \"connectionId\": \"f9c10d29-2cbd-44b0-b909-26ca4108c5dd\",\n \"createdDate\": \"2023-04-05T08:47:48.281Z\",\n \"updatedDate\": \"2023-04-05T08:47:48.281Z\",\n \"expirationDate\": \"2023-04-06T08:47:48.277Z\"\n }\n ]\n }\n}"
}
]
},
{
"name": "Fetch credential by credential id",
"request": {
"method": "GET",
"header": [
{
"key": "Accept",
"value": "application/json"
}
],
"url": {
"raw": "{{baseUrl}}/v1/credential/:id",
"host": ["{{baseUrl}}"],
"path": ["v1", "credential", ":id"],
"variable": [
{
"key": "id",
"value": "f4472554-ee2e-4262-bfc6-0ed268c8be31"
}
]
}
},
"response": [
{
"name": "Fetch credential by credential id",
"originalRequest": {
"method": "GET",
"header": [
{
"key": "Accept",
"value": "application/json"
}
],
"url": {
"raw": "{{baseUrl}}/v1/credential/:id",
"host": ["{{baseUrl}}"],
"path": ["v1", "credential", ":id"],
"variable": [
{
"key": "id",
"value": "f4472554-ee2e-4262-bfc6-0ed268c8be31"
}
]
}
},
"status": "OK",
"code": 200,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Date",
"value": "Fri, 02 Jun 2023 05:58:44 GMT"
},
{
"key": "Content-Type",
"value": "application/json; charset=utf-8"
},
{
"key": "Content-Length",
"value": "525"
},
{
"key": "Connection",
"value": "keep-alive"
},
{
"key": "X-Powered-By",
"value": "Express"
},
{
"key": "Access-Control-Allow-Origin",
"value": "*"
},
{
"key": "ETag",
"value": "W/\"20d-E/63SLfeyJlcwG1mLsRAN1dAc50\""
},
{
"key": "Strict-Transport-Security",
"value": "max-age=15724800; includeSubDomains"
}
],
"cookie": [],
"body": "{\n \"statusCode\": 200,\n \"message\": \"Credential fetched successfully\",\n \"data\": {\n \"id\": \"01b3d49c-1d51-4070-924d-9424ea239a93\",\n \"credentialId\": \"f4472554-ee2e-4262-bfc6-0ed268c8be31\",\n \"credDefId\": \"BsfUfTECZPVRnoCgHUfB3p:3:CL:48687:Automation_CredDef_001\",\n \"threadId\": \"cdb2ce40-970d-4bb2-9d8b-a4aa5e517226\",\n \"state\": \"done\",\n \"principalDid\": \"CuZ94QvJCHihuCBCzRULoc\",\n \"connectionId\": \"2ded97e4-0c8e-470a-8e53-481e24e50db7\",\n \"createdDate\": \"2023-05-15T13:10:52.070Z\",\n \"updatedDate\": \"2023-05-15T13:13:10.164Z\",\n \"expirationDate\": \"2023-05-16T13:10:52.068Z\"\n }\n}"
}
]
},
{
"name": "Create new CredentialType",
"request": {
"method": "POST",
"header": [
{
"key": "Content-Type",
"value": "application/json"
},
{
"key": "Accept",
"value": "application/json"
}
],
"body": {
"mode": "raw",
"raw": "{\n \"type\": \"<string>\",\n \"schemaId\": \"<string>\"\n}",
"options": {
"raw": {
"headerFamily": "json",
"language": "json"
}
}
},
"url": {
"raw": "{{baseUrl}}/v1/credentialType",
"host": ["{{baseUrl}}"],
"path": ["v1", "credentialType"]
}
},
"response": []
},
{
"name": "Fetch CredentialType (schemaId amd its attributes) by type",
"request": {
"method": "GET",
"header": [
{
"key": "Accept",
"value": "application/json"
}
],
"url": {
"raw": "{{baseUrl}}/v1/credentialType",
"host": ["{{baseUrl}}"],
"path": ["v1", "credentialType"]
}
},
"response": []
},
{
"name": "Delete credential (request/offer/proposal) by credential id",
"request": {
"method": "DELETE",
"header": [
{
"key": "Accept",
"value": "application/json"
}
],
"url": {
"raw": "{{baseUrl}}/v1/delete-credential/:id",
"host": ["{{baseUrl}}"],
"path": ["v1", "delete-credential", ":id"],
"variable": [
{
"key": "id"
}
]
}
},
"response": []
},
{
"name": "Health check",
"request": {
"method": "GET",
"header": [
{
"key": "Accept",
"value": "application/json"
}
],
"url": {
"raw": "{{baseUrl}}/v1/health",
"host": ["{{baseUrl}}"],
"path": ["v1", "health"]
}
},
"response": [
{
"name": "Health check",
"originalRequest": {
"method": "GET",
"header": [
{
"key": "Accept",
"value": "application/json"
}
],
"url": {
"raw": "{{baseUrl}}/v1/health",
"host": ["{{baseUrl}}"],
"path": ["v1", "health"]
}
},
"status": "OK",
"code": 200,
"_postman_previewlanguage": "json",
"header": [
{
"key": "Date",
"value": "Fri, 02 Jun 2023 05:54:20 GMT"
},
{
"key": "Content-Type",
"value": "application/json; charset=utf-8"
},
{
"key": "Content-Length",
"value": "93"
},
{
"key": "Connection",
"value": "keep-alive"
},
{
"key": "X-Powered-By",
"value": "Express"
},
{
"key": "Access-Control-Allow-Origin",
"value": "*"
},
{
"key": "ETag",
"value": "W/\"5d-n7tsAF97fIhtcEb5uvvhp8pNSHg\""
},
{
"key": "Strict-Transport-Security",
"value": "max-age=15724800; includeSubDomains"
}
],
"cookie": [],
"body": "{\n \"statusCode\": 200,\n \"message\": \"Fri Jun 02 2023 05:54:20 GMT+0000 (Coordinated Universal Time)\"\n}"
}
]
},
{
"name": "Fetch list of Schemas with pagination",
"request": {
"method": "GET",
"header": [
{
"key": "Accept",
"value": "application/json"
}
],
"url": {
"raw": "{{baseUrl}}/v1/schemas",
"host": ["{{baseUrl}}"],
"path": ["v1", "schemas"]
}
},
"response": []
},
{
"name": "Create new schema",
"request": {
"method": "POST",
"header": [
{
"key": "Content-Type",
"value": "application/json"
},
{
"key": "Accept",
"value": "application/json"
}
],
"body": {
"mode": "raw",
"raw": "{\n \"name\": \"<string>\",\n \"createdBy\": \"<string>\",\n \"version\": \"<string>\",\n \"attributes\": [\n \"<string>\",\n \"<string>\"\n ],\n \"type\": \"<string>\"\n}",
"options": {
"raw": {
"headerFamily": "json",
"language": "json"
}
}
},
"url": {
"raw": "{{baseUrl}}/v1/schemas",
"host": ["{{baseUrl}}"],
"path": ["v1", "schemas"]
}
},
"response": []
},
{
"name": "Fetch list of dids for schema id",
"request": {
"method": "GET",
"header": [
{
"key": "Accept",
"value": "application/json"
}
],
"url": {
"raw": "{{baseUrl}}/v1/schemas/get-dids-for-schema/:id",
"host": ["{{baseUrl}}"],
"path": ["v1", "schemas", "get-dids-for-schema", ":id"],
"variable": [
{
"key": "id",
"value": "<string>"
}
]
}
},
"response": []
},
{
"name": "Fetch list of Schemas by schema id",
"request": {
"method": "GET",
"header": [
{
"key": "Accept",
"value": "application/json"
}
],
"url": {
"raw": "{{baseUrl}}/v1/schemas/:id",
"host": ["{{baseUrl}}"],
"path": ["v1", "schemas", ":id"],
"variable": [
{
"key": "id",
"value": "<string>"
}
]
}
},
"response": []
},
{
"name": "Update schemaId in CredentialsType",
"request": {
"method": "PATCH",
"header": [
{
"key": "Content-Type",
"value": "application/json"
},
{
"key": "Accept",
"value": "application/json"
}
],
"body": {
"mode": "raw",
"raw": "{\n \"schemaId\": \"<string>\"\n}",
"options": {
"raw": {
"headerFamily": "json",
"language": "json"
}
}
},
"url": {
"raw": "{{baseUrl}}/v1/updateSchemaIdByType",
"host": ["{{baseUrl}}"],
"path": ["v1", "updateSchemaIdByType"]
}
},
"response": []
},
{
"name": "Add user information associated with connection id",
"request": {
"method": "POST",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"body": {
"mode": "raw",
"raw": "{\n \"connectionId\": \"<string>\",\n \"autoAcceptCredential\": \"<string>\",\n \"userInfo\": {}\n}",
"options": {
"raw": {
"headerFamily": "json",
"language": "json"
}
}
},
"url": {
"raw": "{{baseUrl}}/v1/userInfo",
"host": ["{{baseUrl}}"],
"path": ["v1", "userInfo"]
}
},
"response": []
}
],
"event": [
{
"listen": "prerequest",
"script": {
"type": "text/javascript",
"exec": [""]
}
},
{
"listen": "test",
"script": {
"type": "text/javascript",
"exec": [""]
}
}
],
"variable": [
{
"key": "baseUrl",
"value": "https://ssi-dev.vereign.com/ocm/attestation"
}
]
}
GAIA-X "Attestation Manager"
is the microservice which is responsible for handling the features
related to issuance of credentials of the GAIA-X project. It handles REST
endpoints for Schemas, Credential Definitions and Verifiable Credentials.
Copyright 2022 Vereign AG
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
This Attestation Manager incorporates
"elastic/ecs-winston-format",
a Node.js package to provide a formatter for the winston logger compatible
with Elastic Common Schema (ECS) logging, which is covered by the following copyright
and permission notice:
Copyright 2020 Elastic and contributors
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
This Attestation Manager also incorporates
"nestjs",
a progressive Node.js framework for building efficient and scalable server-side applications,
which is covered by the following copyright and permission notice:
Copyright (c) 2017-2022 Kamil Mysliwiec <https://kamilmysliwiec.com>
(The MIT License)
Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
'Software'), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:
The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
This Attestation Manager also incorporates
"nestjs/terminus"
, integrated healthchecks for Nest, which contains the
following copyright and permission notice:
Copyright (c) 2018-2021 Livio Brunner, Kamil Myśliwiec
(The MIT License)
Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
'Software'), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:
The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
This Attestation Manager also incorporates
"prisma client"
,an auto-generated query builder that enables type-safe database access and reduces
boilerplate, which is covered by the following copyright and permission notice:
Copyright 2019 Johannes Schickling
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
This Attestation Manager also incorporates
"types/node"
,type definitions for Node, which is covered by the following copyright and
permission notice:
Copyright Microsoft TypeScript, DefinitelyTyped, Alberto Schiabel,
Alvis HT Tang, Andrew Makarov, Benjamin Toueg, Chigozirim C., David Junger, Deividas Bakanas, Eugene Y. Q. Shen,
Hannes Magnusson, Huw, Kelvin Jin, Klaus Meinhardt, Lishude, Mariusz Wiktorczyk, Mohsen Azimi, Nicolas Even,
Nikita Galkin, Parambir Singh, Sebastian Silbermann, Simon Schick, Thomas den Hollander, Wilco Bakker, wwwy3y3,
Samuel Ainsworth, Kyle Uehlein, Thanik Bhongbhibhat, Marcin Kopacz, Trivikram Kamat, Junxiao Shi, Ilia Baryshnikov,
ExE Boss, Piotr Błażejewicz, Anna Henningsen, Victor Perin, Yongsheng Zhang, NodeJS Contributors,
Linus Unnebäck, wafuwafu13, and Matteo Collina.
(The MIT License)
Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
'Software'), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:
The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
This Attestation Manager also incorporates
"types/express"
,type definitions for Express (http://expressjs.com), which is covered by the following
copyright and permission notice:
Copyright Boris Yankov, China Medical University Hospital, Puneet Arora, and Dylan Frankland.
(The MIT License)
Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
'Software'), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:
The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
This Attestation Manager also incorporates
"types/jest"
type definitions for Jest, which is covered by the following copyright and permission notice:
Copyright Asana (https://asana.com)// Ivo Stratev, jwbay, Alexey Svetliakov, Alex Jover Morales, Allan Lukwago,
Ika, Waseem Dahman, Jamie Mason, Douglas Duteil, Ahn, Jeff Lau, Andrew Makarov, Martin Hochel, Sebastian Sebald,
Andy, Antoine Brault, Gregor Stamać, ExE Boss, Alex Bolenok, Mario Beltrán Alarcón, Tony Hallett, Jason Yu, Pawel Fajfer,
Regev Brody, Alexandre Germain, and Adam Jones.
(The MIT License)
Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
'Software'), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:
The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
This Attestation Manager also incorporates
"class-validator"
, a tool to allow decorator and non-decorator based validation,
and
"class-transformer"
,a tool to transform plain object to some instance of class and versa, also to serialize /
deserialize object based on criteria, both of which are covered by the following copyright
and permission notice:
Copyright 2015-2020 TypeStack
(The MIT License)
Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
'Software'), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:
The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
This Attestation Manager also incorporates
"express"
,a fast, unopinionated, minimalist web framework for node, which is covered by the following copyright
and permission notice:
Copyright (c) 2009-2014 TJ Holowaychuk <tj@vision-media.ca>
Copyright (c) 2013-2014 Roman Shtylman <shtylman+expressjs@gmail.com>
Copyright (c) 2014-2015 Douglas Christopher Wilson <doug@somethingdoug.com>
(The MIT License)
Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
'Software'), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:
The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
This Attestation Manager also incorporates
"husky"
, modern native Git hooks made easy, which is covered by the following copyright and
permission notice:
Copyright (c) 2021 typicode
(The MIT License)
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
This Attestation Manager also incorporates
"joi"
, the most powerful schema description language and data validator for JavaScript, which is
covered by the following copyright and permission notice:
Copyright (c) 2012-2020, Sideway. Inc, and project contributors.
Copyright (c) 2012-2014, Walmart.
All rights reserved.
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
- Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
- Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or
other materials provided with the distribution.
- The names of any contributors may not be used to endorse or promote products derived from this software without
specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDERS AND CONTRIBUTORS
BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
This Attestation Manager also incorporates
"liquibase"
, liquibase is an open-source database-independent library for tracking, managing and applying database schema change, which is covered
by the following copyright and permission notice:
Copyright (c) Taylor Buckner <taylora.buckner@gmail.com>
(The MIT License)
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
This Attestation Manager also incorporates
"moment"
, a JavaScript date library for parsing, validating, manipulating, and formatting dates,
which is covered by the following copyright and permission notice:
Copyright (c) JS Foundation and other contributors
(The MIT License)
Permission is hereby granted, free of charge, to any person
obtaining a copy of this software and associated documentation
files (the "Software"), to deal in the Software without
restriction, including without limitation the rights to use,
copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following
conditions:
The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
OTHER DEALINGS IN THE SOFTWARE.
This Attestation Manager also incorporates
"nats"
, a Node.js client for the NATS messaging system, which is covered by
the following copyright and permission notice:
Copyright 2013-2018 The NATS Authors
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
This Attestation Manager also incorporates
"pg - node postgres"
, non-blocking PostgreSQL client for Node.js, which is covered by
the following copyright and permission notice:
Copyright (c) 2010-2020 Brian Carlson (brian.m.carlson@gmail.com)
(The MIT License)
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in the
Software without restriction, including without limitation the rights to use, copy,
modify, merge, publish, distribute, sublicense, and/or sell copies of the Software,
and to permit persons to whom the Software is furnished to do so, subject to the
following conditions:
The above copyright notice and this permission notice shall be included in all copies
or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
This Attestation Manager also incorporates
"prisma"
, next-generation ORM for Node.js & TypeScript | PostgreSQL, MySQL, MariaDB, SQL Server,
SQLite, MongoDB and CockroachDB, which is covered by the following copyright and
permission notice:
Copyright 2019 Johannes Schickling
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
This Attestation Manager also incorporates
"reflect-metadata"
, prototype for a Metadata Reflection API for ECMAScript, which is covered
by the following copyright and permission notice:
Copyright 2019 Ron Buckton
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
This Attestation Manager also incorporates
"rimraf"
, a `rm -rf` util for nodejs, which is covered by the following copyright
and permission notice:
Copyright (c) 2011-2022 Isaac Z. Schlueter and Contributors
(The ISC License)
Permission to use, copy, modify, and/or distribute this software for any
purpose with or without fee is hereby granted, provided that the above
copyright notice and this permission notice appear in all copies.
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR
IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
This Attestation Manager also incorporates
"rxjs"
, reactive extensions for JavaScript, which is covered by the following copyright
and permission notice:
Copyright (c) 2015-2018 Google, Inc., Netflix, Inc., Microsoft Corp. and contributors
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
This Attestation Manager also incorporates
"Swagger UI Express"
, allows to serve auto-generated swagger-ui generated API docs from express,
based on a swagger.json file, which is covered by the following copyright and
permission notice:
Copyright (c) 2018 Scott IT London
(The MIT License)
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
This Attestation Manager also incorporates
"winston"
, a logger for just about everything, which is covered by the following copyright and
permission notice:
Copyright (c) 2010 Charlie Robbins
(The MIT License)
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
This Attestation Manager also incorporates
"winston-elasticsearch"
, an elasticsearch transport for winston, which is covered by the following copyright and
permission notice:
Copyright (c) 2015 - 2018 Thomas Hoppe.
Copyright (c) 2013 Jacques-Olivier D. Bernier.
(The MIT License)
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
# OCM Attestation Manager
## Description
<hr/>
The Attestation Manager is the microservice responsible for handling the features related to Issuance of Credentials. It handles REST endpoints for Schemas, Credential Definitions and Verifiable Credentials.
## Usage
<hr/>
### Swagger Documentation:
[Swagger/OpenAPI](swagger.json)
## Installation
<hr/>
### Pre-requisite
- pnpm
- docker
- docker-compose
- PostgreSQL
### OCM Services Dependencies
- SSI Abstraction
- Connection Manager
## Running the app
**Each service in the Organizational Credential Manager can be run from the infrastructure repository with Docker.**
**The .env files are in the infrastructure repository under /env**
```bash
## production in:
./deployment/ci
## development in:
./deployment/dev
```
- (optional) Edit docker-compose.yml in "infrastructure" to use either **/ci/** or **/dev/** Dockerfiles.
- Run while in **"infrastructure"** project:
```bash
$ docker-compose up --build attestation-m
```
to run only Attestation Manager or
```bash
$ docker-compose up --build
```
to run all the services.
## Build
```
pnpm build
```
## Run
```
pnpm start
```
### Environment Variables Required
```
1. PORT
2. DATABASE_URL
3. ECSURL
4. NATS_URL
5. AGENT_URL
```
### Outgoing communication services
```
1. SSI Abstraction
```
### Incomming communication services
```
1. Principal Manager
```
### Features supported
```
1. Create Schema
2. Create Credential Definition
3. Offer Credentials
4. Propose Credentials
5. Accept Credential
```
## Test
<hr/>
```bash
# unit tests
$ pnpm test
# e2e tests
$ pnpm test:e2e
# test coverage
$ pnpm test:cov
```
## GDPR
<hr/>
[GDPR](GDPR.md)
## Dependencies
<hr/>
[Dependencies](package.json)
## License
<hr/>
[Apache 2.0 license](LICENSE)
apiVersion: v1
appVersion: v1.0.4-rc
description: attestation-manager deployment
name: attestation-manager
version: 1.0.4
icon: 'https://www.vereign.com/wp-content/themes/vereign2020/images/vereign-logo.svg'
Deployment recipe for OCM attestation manager.
Copyright 2022 Vereign AG
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
# attestation-manager
![Version: 1.0.1](https://img.shields.io/badge/Version-1.0.1-informational?style=flat-square) ![AppVersion: v1.0.1-rc](https://img.shields.io/badge/AppVersion-v1.0.1--rc-informational?style=flat-square)
attestation-manager deployment
## Values
| Key | Type | Default | Description |
| ----------------------------------------------------------------- | ------ | ------------------------------------------------------- | -------------------------------------------------------------- |
| attestationManager.acceptMembershipCredentialsConfig | string | `"AUTO"` | |
| attestationManager.agent.host | string | `"ssi-abstraction"` | |
| attestationManager.agent.port | int | `3010` | |
| attestationManager.agent.protocol | string | `"http"` | |
| attestationManager.database.db | string | `"ocm_attestation_manager"` | |
| attestationManager.database.host | string | `"postgresql-postgresql-ha-postgresql.infra"` | |
| attestationManager.database.password | string | `"ocm_attestation_manager"` | |
| attestationManager.database.port | int | `5432` | |
| attestationManager.database.schema | string | `"attestation"` | |
| attestationManager.database.user | string | `"ocm_attestation_manager"` | |
| attestationManager.elastic.port | int | `9200` | |
| attestationManager.elastic.protocol | string | `"http"` | |
| attestationManager.elastic.url | string | `"elasticsearch"` | |
| attestationManager.nats.port | int | `4222` | |
| attestationManager.nats.protocol | string | `"nats"` | |
| attestationManager.nats.url | string | `"nats"` | |
| attestationManager.url.attestationManager | string | `"https://gaiax.vereign.com/ocm/attestation"` | |
| attestationManager.url.connectionManager | string | `"https://gaiax.vereign.com/ocm/connection"` | |
| attestationManager.url.tsa | string | `"https://gaiax.vereign.com/tsa/policy/policy/example"` | |
| autoscaling.enabled | bool | `false` | Enable autoscaling |
| autoscaling.maxReplicas | int | `3` | Maximum replicas |
| autoscaling.minReplicas | int | `1` | Minimum replicas |
| autoscaling.targetCPUUtilizationPercentage | int | `70` | CPU target for autoscaling trigger |
| autoscaling.targetMemoryUtilizationPercentage | int | `70` | Memory target for autoscaling trigger |
| image.name | string | `"gaiax/attestation-manager"` | Image name |
| image.pullPolicy | string | `"IfNotPresent"` | Image pull policy |
| image.pullSecrets | string | `"deployment-key-light"` | Image pull secret when internal image is used |
| image.repository | string | `"eu.gcr.io/vrgn-infra-prj"` | |
| image.sha | string | `""` | Image sha, usually generated by the CI Uses image.tag if empty |
| image.tag | string | `""` | Image tag Uses .Chart.AppVersion if empty |
| ingress.annotations."cert-manager.io/cluster-issuer" | string | `"letsencrypt-production-http"` | |
| ingress.annotations."kubernetes.io/ingress.class" | string | `"nginx"` | |
| ingress.annotations."kubernetes.io/ingress.global-static-ip-name" | string | `"dev-light-public"` | |
| ingress.annotations."nginx.ingress.kubernetes.io/rewrite-target" | string | `"/$2"` | |
| ingress.enabled | bool | `true` | |
| ingress.frontendDomain | string | `"gaiax.vereign.com"` | |
| ingress.frontendTlsSecretName | string | `"cert-manager-tls"` | |
| ingress.tlsEnabled | bool | `true` | |
| log.encoding | string | `"json"` | |
| log.level | string | `"INFO"` | |
| metrics.enabled | bool | `true` | Enable prometheus metrics |
| metrics.port | int | `2112` | Port for prometheus metrics |
| name | string | `"ssi-abstraction"` | Application name |
| nameOverride | string | `""` | Ovverwrites application name |
| podAnnotations | object | `{}` | |
| replicaCount | int | `1` | Default number of instances to start |
| resources.limits.cpu | string | `"150m"` | |
| resources.limits.memory | string | `"128Mi"` | |
| resources.requests.cpu | string | `"25m"` | |
| resources.requests.memory | string | `"64Mi"` | |
| security.runAsGid | int | `0` | Group used by the apps |
| security.runAsNonRoot | bool | `false` | by default, apps run as non-root |
| security.runAsUid | int | `0` | User used by the apps |
| service.port | int | `3005` | |
---
Autogenerated from chart metadata using [helm-docs v1.10.0](https://github.com/norwoodj/helm-docs/releases/v1.10.0)
{{/* vim: set filetype=mustache: */}}
{{/*
Expand the name of the chart.
*/}}
{{- define "app.name" -}}
{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" -}}
{{- end -}}
{{/*
Create a fully qualified app name.
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
*/}}
{{- define "app.fullname" -}}
{{- $name := default .Chart.Name .Values.nameOverride -}}
{{- printf "%s-%s" $name .Release.Namespace | trunc 63 | trimSuffix "-" -}}
{{- end -}}
{{/*
Create instance name based on app version and short image sha.
*/}}
{{- define "app.revision" -}}
{{- default .Release.Name .Values.appRel | trunc 63 | trimSuffix "-" -}}
{{- end -}}
{{/*
Create chart name and version as used by the chart label.
*/}}
{{- define "app.chart" -}}
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" -}}
{{- end -}}
{{/*
Common labels
*/}}
{{- define "app.labels" -}}
helm.sh/chart: {{ include "app.chart" . }}
{{ include "app.selectorLabels" . }}
app.kubernetes.io/version: {{ .Chart.AppVersion }}
app.kubernetes.io/managed-by: {{ .Release.Service }}
{{- end -}}
{{/*
Selector labels
*/}}
{{- define "app.selectorLabels" -}}
app.kubernetes.io/name: {{ include "app.name" . }}
app.kubernetes.io/component: {{ include "app.fullname" . }}
{{- end -}}
{{/*
Metrics Annotations
*/}}
{{- define "app.metricsAnnotations" -}}
{{- if .Values.metrics.enabled -}}
prometheus.io/scrape: "true"
prometheus.io/port: "{{ .Values.metrics.port }}"
prometheus.io/path: {{ .Values.metrics.path | default "/metrics" | quote }}
{{- end -}}
{{- end -}}
{{/*
Image string
*/}}
{{- define "app.image" -}}
{{- if .Values.image.sha -}}
{{ .Values.image.repository }}/{{ .Values.image.name }}@{{ .Values.image.sha }}
{{- else -}}
{{ .Values.image.repository }}/{{ .Values.image.name }}:{{ default .Chart.AppVersion .Values.image.tag }}
{{- end -}}
{{- end -}}
{{/*
Security context
*/}}
{{- define "app.securitycontext" -}}
runAsNonRoot: {{ .Values.security.runAsNonRoot | default false }}
runAsGroup: {{ .Values.security.runAsGid | default 0 }}
runAsUser: {{ .Values.security.runAsUid | default 0 }}
fsGroup: {{ .Values.security.runAsGid | default 0 }}
{{- end -}}
{{/*
PostgreSQL Connection string URI
*/}}
{{- define "app.postgresql.connectionstring" -}}
postgresql://{{ .Values.attestationManager.database.user }}:{{ .Values.attestationManager.database.password }}@{{ .Values.attestationManager.database.host }}:{{ .Values.attestationManager.database.port }}/{{ .Release.Namespace }}_{{ include "app.name" . | replace "-" "_" }}?schema={{ .Values.attestationManager.database.schema }}
{{- end -}}
{{/*
Ingress custom path.
*/}}
{{- define "app.path" -}}
{{- default .Chart.Name .Values.ingress.pathOverride | replace "-manager" "" | trunc 63 | trimSuffix "-" -}}
{{- end -}}
apiVersion: apps/v1
kind: Deployment
metadata:
name: "{{ template "app.name" . }}"
namespace: {{ .Release.Namespace }}
labels:
{{- include "app.labels" . | nindent 4 }}
app.kubernetes.io/instance: {{ include "app.revision" . }}
app.kubernetes.io/part-of: rse
spec:
replicas: {{ .Values.replicaCount }}
strategy:
type: RollingUpdate
rollingUpdate:
maxSurge: 1
maxUnavailable: 0
selector:
matchLabels:
{{- include "app.selectorLabels" . | nindent 6 }}
template:
metadata:
labels:
{{- include "app.labels" . | nindent 8 }}
annotations:
{{- include "app.metricsAnnotations" . | nindent 8 }}
{{- if .Values.podAnnotations }}
{{ toYaml .Values.podAnnotations | indent 8 }}
{{- end }}
spec:
securityContext:
{{- include "app.securitycontext" . | nindent 8 }}
imagePullSecrets:
- name: {{ .Values.image.pullSecrets }}
containers:
- name: {{ template "app.name" . }}
image: "{{ .Values.image.repository }}/{{ .Values.image.name }}:{{ default .Chart.AppVersion .Values.image.tag }}"
imagePullPolicy: {{ .Values.image.pullPolicy | quote }}
env:
- name: PORT
value: {{ .Values.service.port | quote }}
- name: DATABASE_URL
value: {{ template "app.postgresql.connectionstring" (merge (dict "application" "true") .) }}
- name: NATS_URL
value: "{{ .Values.attestationManager.nats.protocol }}://{{ .Values.attestationManager.nats.url }}:{{ .Values.attestationManager.nats.port }}"
- name: ECSURL
value: "{{ .Values.attestationManager.elastic.protocol }}://{{ .Values.attestationManager.elastic.url }}:{{ .Values.attestationManager.elastic.port }}/"
- name: LOG_LEVEL
value: {{ .Values.log.level | default "INFO" }}
- name: LOG_ENCODING
value: {{ .Values.log.encoding | default "json" }}
- name: AGENT_URL
value: "{{ .Values.attestationManager.agent.protocol }}://{{ .Values.attestationManager.agent.host }}:{{ .Values.attestationManager.agent.port }}"
- name: ACCEPT_MEMBERSHIP_CREDENTIALS_CONFIG
value: {{ .Values.attestationManager.acceptMembershipCredentialsConfig }}
- name: TSA_URL
value: {{ .Values.attestationManager.url.tsa }}
- name: CONNECTION_MANAGER_URL
value: {{ .Values.attestationManager.url.connectionManager }}
- name: ATTESTATION_MANAGER_URL
value: {{ .Values.attestationManager.url.attestationManager }}
{{- if .Values.extraVars }}
{{ toYaml .Values.extraVars | indent 8 }}
{{- end }}
ports:
{{- if .Values.metrics.enabled }}
- name: monitoring
containerPort: {{ .Values.metrics.port }}
{{- end }}
- name: http
containerPort: {{ .Values.service.port }}
readinessProbe:
httpGet:
path: /v1/health
port: {{ .Values.service.port }}
initialDelaySeconds: 5
periodSeconds: 5
successThreshold: 2
failureThreshold: 2
timeoutSeconds: 5
resources:
{{ toYaml .Values.resources | indent 10 }}
{{- if .Values.ingress.enabled }}
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: {{ template "app.path" . }}
namespace: {{ .Release.Namespace }}
annotations:
{{ toYaml .Values.ingress.annotations | indent 4 }}
labels:
{{- include "app.labels" . | nindent 4 }}
spec:
{{- if .Values.ingress.tlsEnabled }}
tls:
- hosts:
- {{ .Values.ingress.frontendDomain }}
secretName: {{ .Values.ingress.frontendTlsSecretName }}
{{- end }}
rules:
- host: {{ .Values.ingress.frontendDomain }}
http:
paths:
- path: /{{ template "app.path" . }}(/|$)(.*)
pathType: Prefix
backend:
service:
name: {{ template "app.name" . }}
port:
number: {{ .Values.service.port }}
{{- end }}
\ No newline at end of file
apiVersion: v1
kind: Service
metadata:
name: { { template "app.name" . } }
namespace: { { .Release.Namespace } }
labels: { { - include "app.labels" . | nindent 4 } }
spec:
clusterIP: None
ports:
- name: http
port: { { .Values.service.port } }
targetPort: { { .Values.service.port } }
selector: { { - include "app.selectorLabels" . | nindent 4 } }