Skip to content

Commit 21b0336

Browse files
authored
Merge pull request #368 from credebl/merge/main-sync-to-main
merge: main sync (OID4VC/P) to main
2 parents 104f72a + a97f464 commit 21b0336

95 files changed

Lines changed: 18244 additions & 9102 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.env.demo

Lines changed: 94 additions & 141 deletions
Large diffs are not rendered by default.

.env.sample

Lines changed: 96 additions & 142 deletions
Large diffs are not rendered by default.

.sonarcloud.properties

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
sonar.exclusions=samples/cliConfig.json,src/routes/routes.ts

Dockerfile

Lines changed: 17 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Stage 1: Builder stage
2-
FROM node:18.19.0 AS builder
2+
FROM node:22.22.0 AS builder
33

44
WORKDIR /app
55

@@ -18,8 +18,15 @@ RUN yarn global add patch-package
1818
# Build the application
1919
RUN yarn build
2020

21-
# Stage 2: Production stage
22-
FROM node:18.19.0-slim
21+
# Stage 2: Production stage
22+
FROM node:22.22.0-slim
23+
24+
# Update system packages and install security updates
25+
RUN apt-get update && apt-get upgrade -y && \
26+
apt-get install -y --no-install-recommends \
27+
ca-certificates && \
28+
apt-get clean && \
29+
rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
2330

2431
WORKDIR /app
2532

@@ -30,5 +37,12 @@ COPY --from=builder /app/package.json ./
3037
COPY --from=builder /app/node_modules ./node_modules
3138
COPY --from=builder /app/patches ./patches
3239

40+
# Create non-root user for security
41+
RUN groupadd -r appuser && useradd -r -g appuser appuser && \
42+
chown -R appuser:appuser /app && \
43+
chmod -R 755 /app
44+
45+
USER appuser
46+
3347
# Set entry point
3448
ENTRYPOINT ["node", "./bin/afj-rest.js", "start"]

eslint.config.mjs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,12 +9,12 @@ const __filename = fileURLToPath(import.meta.url);
99
const __dirname = dirname(__filename);
1010

1111
export default [
12+
{
13+
ignores: ['**/build/**', '**/*.js', '**/*.d.ts'],
14+
},
1215
{
1316
ignores: [
14-
'**/tests/*',
15-
'**/build/**',
16-
'**/*.js',
17-
'**/*.d.ts',
17+
'**/tests/*',
1818
],
1919
files: ['**/*.ts'],
2020
languageOptions: {

package.json

Lines changed: 24 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -39,18 +39,20 @@
3939
"validate": "yarn lint && yarn check-types && yarn check-format"
4040
},
4141
"dependencies": {
42-
"@ayanworks/credo-polygon-w3c-module": "1.0.1-alpha.1",
43-
"@credo-ts/anoncreds": "0.5.15",
44-
"@credo-ts/askar": "0.5.15",
45-
"@credo-ts/core": "0.5.15",
46-
"@credo-ts/indy-vdr": "0.5.15",
47-
"@credo-ts/node": "^0.5.15",
42+
"@ayanworks/credo-polygon-w3c-module": "2.0.2",
43+
"@sd-jwt/jwt-status-list": "0.19.0",
44+
"@credo-ts/anoncreds": "0.6.2",
45+
"@credo-ts/askar": "0.6.2",
46+
"@credo-ts/core": "0.6.2",
47+
"@credo-ts/didcomm": "0.6.2",
48+
"@credo-ts/indy-vdr": "0.6.2",
49+
"@credo-ts/node": "0.6.2",
50+
"@credo-ts/openid4vc": "0.6.2",
4851
"@credo-ts/push-notifications": "^0.7.1",
49-
"@credo-ts/question-answer": "0.5.15",
50-
"@credo-ts/tenants": "0.5.15",
51-
"@hyperledger/anoncreds-nodejs": "0.3.1",
52-
"@hyperledger/aries-askar-nodejs": "0.2.3",
53-
"@hyperledger/indy-vdr-nodejs": "0.2.2",
52+
"@credo-ts/question-answer": "0.6.2",
53+
"@credo-ts/tenants": "0.6.2",
54+
"@hyperledger/anoncreds-nodejs": "^0.3.4",
55+
"@hyperledger/indy-vdr-nodejs": "^0.2.3",
5456
"@opentelemetry/api": "^1.9.0",
5557
"@opentelemetry/exporter-logs-otlp-http": "^0.202.0",
5658
"@opentelemetry/exporter-trace-otlp-http": "^0.202.0",
@@ -61,26 +63,30 @@
6163
"@opentelemetry/sdk-logs": "^0.202.0",
6264
"@opentelemetry/sdk-node": "^0.202.0",
6365
"@opentelemetry/semantic-conventions": "^1.34.0",
66+
"@openwallet-foundation/askar-nodejs": "^0.4.3",
6467
"@tsoa/runtime": "^6.6.0",
6568
"@types/node-fetch": "^2.6.4",
6669
"@types/ref-struct-di": "^1.1.12",
6770
"@types/uuid": "^10.0.0",
6871
"@types/ws": "^8.18.1",
69-
"axios": "^1.9.0",
72+
"axios": "1.13.5",
7073
"body-parser": "^2.2.0",
7174
"cors": "^2.8.5",
7275
"dotenv": "^16.5.0",
7376
"express": "^5.1.0",
7477
"express-rate-limit": "^7.5.0",
7578
"joi": "^17.13.3",
7679
"jsonwebtoken": "^9.0.2",
80+
"nats": "^2.29.3",
81+
"node-cron": "^4.2.1",
7782
"node-fetch": "2",
7883
"patch-package": "^8.0.0",
7984
"reflect-metadata": "^0.2.2",
8085
"swagger-ui-express": "^4.4.0",
8186
"tslog": "^3.3.3",
8287
"tsoa": "^6.0.1",
83-
"tsyringe": "^4.8.0",
88+
"tsyringe": "^4.10.0",
89+
"uuid": "^13.0.0",
8490
"ws": "^8.18.2",
8591
"yargs": "^17.7.2"
8692
},
@@ -94,6 +100,7 @@
94100
"@types/jsonwebtoken": "^9.0.9",
95101
"@types/multer": "^1.4.12",
96102
"@types/node": "^20.17.0",
103+
"@types/node-cron": "^3.0.11",
97104
"@types/ref-array-di": "^1.2.8",
98105
"@types/ref-struct-di": "^1.1.12",
99106
"@types/supertest": "^6.0.3",
@@ -115,7 +122,9 @@
115122
"typescript": "^5.8.3"
116123
},
117124
"resolutions": {
118-
"@credo-ts/core": "0.5.15",
119-
"@credo-ts/askar": "0.5.15"
125+
"@credo-ts/core": "0.6.2",
126+
"@credo-ts/askar": "0.6.2",
127+
"flatted": "3.4.0",
128+
"undici": "6.24.0"
120129
}
121130
}

patches/@credo-ts+anoncreds+0.5.3+001+fix: Extensible model confict in Anoncreds and Did.patch

Lines changed: 0 additions & 272 deletions
This file was deleted.

patches/@credo-ts+core+0.5.15+001+message-type-for-messages.patch

Lines changed: 0 additions & 43 deletions
This file was deleted.

patches/@credo-ts+core+0.5.15+003+added-prettyVc-in-JsonCredential-interface.patch

Lines changed: 0 additions & 13 deletions
This file was deleted.

patches/@credo-ts+core+0.5.15+004+commenting validationPresentation to avoid abandoned issue.patch

Lines changed: 0 additions & 27 deletions
This file was deleted.

0 commit comments

Comments
 (0)