Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
50 commits
Select commit Hold shift + click to select a range
cfd2058
remove sdk/tests (#622)
remicolin Jun 13, 2025
095ceeb
fix: add range check on paddedInLength of shaBytesDynamic (#623)
Vishalkulkarni45 Jun 15, 2025
9efe1b0
fix ci (#626)
remicolin Jun 16, 2025
7cab29d
implement self uups upgradeable (#592)
motemotech Jun 16, 2025
aca1474
prettier (#629)
motemotech Jun 16, 2025
498b89c
CAN auth - android (#613)
seshanthS Jun 16, 2025
e99e473
feat: add MRZ correction method to NFCMethodSelectionScreen (#627)
seshanthS Jun 16, 2025
6750848
add npm auth token env (#632)
remicolin Jun 16, 2025
f3f7028
bump sdk version (#633)
remicolin Jun 16, 2025
4e57997
publish npm package when merging on dev
remicolin Jun 16, 2025
2d53b89
bump common sdk version
remicolin Jun 16, 2025
40edfd7
replace yarn publish by npm publish
remicolin Jun 16, 2025
cfed790
update common package version
remicolin Jun 17, 2025
08c1ead
Simplify dev mode gesture (#635)
remicolin Jun 17, 2025
f00b21d
add build smt function to common sdk
remicolin Jun 17, 2025
27990f0
update vc_and_disclose_id test (dev branch) (#641)
Vishalkulkarni45 Jun 18, 2025
93312c0
Show modal on NFC scan error (#642)
remicolin Jun 18, 2025
e4541a8
Bump build v2.5.4: ios 132; android 71 (#631)
transphorm Jun 18, 2025
d89d202
fix: update TD1 and TD3 checks (#643)
seshanthS Jun 19, 2025
63b21a1
bum yarn.lock
remicolin Jun 19, 2025
ae0dca3
Bump build: ios 133; android 72 and build fixes (#654)
transphorm Jun 21, 2025
df13f4e
Update example contracts to include EUID usage (#656)
kevinsslin Jun 22, 2025
2607dac
cherry pick commit from add-test-self-verification...
kevinsslin Jun 21, 2025
ddcaac9
block non-dev pr to main branch
remicolin Jun 22, 2025
a193278
audit fixes (#645)
Nesopie Jun 22, 2025
f769680
Update deployment module for Identity Verification Hub V2 with detail…
kevinsslin Jun 23, 2025
d79563c
publish npm-package (#651)
motemotech Jun 23, 2025
be83be9
merge main
Nesopie Jun 23, 2025
0468719
App/eu id updates (#638)
remicolin Jun 23, 2025
02a0ee3
Hotfix contract compile error (#660)
kevinsslin Jun 23, 2025
72a7f81
Fix/sdk (#652)
Nesopie Jun 23, 2025
42eff71
Update npm-publish workflow and bump core package version to 1.0.0 (#…
Nesopie Jun 23, 2025
aa0cb50
update import
remicolin Jun 23, 2025
b3e4d13
Update get verification config visibility (#664)
kevinsslin Jun 23, 2025
60bfe43
Apply BUSL v1.1 license headers to app (#665)
transphorm Jun 23, 2025
f08cfe1
bump build: android 73 (#659)
seshanthS Jun 23, 2025
dd02d04
Contracts/deploy staging (#668)
remicolin Jun 23, 2025
9e74f11
bump ios build and version (#669)
transphorm Jun 23, 2025
c2e958f
configure coderabbitai (#670)
transphorm Jun 24, 2025
4d4efff
Apply BSL to app codebase (#639)
ericnakagawa Jun 24, 2025
37528f8
SEL-423 apply xcode build suggestions (#671)
transphorm Jun 24, 2025
22681b1
Circuit audit fixes (#644)
Vishalkulkarni45 Jun 24, 2025
6f53872
bump core version
remicolin Jun 24, 2025
0a17717
bump core version and fix ci
Nesopie Jun 24, 2025
5f5eb90
chore: use npm_auth_token in yarnrc
Nesopie Jun 24, 2025
018da75
chroe: rm yarnrc changes
Nesopie Jun 24, 2025
8e5065a
chore: update npm publish
Nesopie Jun 24, 2025
bc486e1
chore: run npm publish manually
Nesopie Jun 24, 2025
12e3598
chore: change hub contract address (#675)
Nesopie Jun 24, 2025
650e9b9
Update npm-publish.yml
Nesopie Jun 24, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
64 changes: 64 additions & 0 deletions .coderabbit.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
# yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

language: "en-US"
tone_instructions: |
You are an expert code reviewer for a React Native/TypeScript mobile application with smart contract integration.
Focus on security, performance, and best practices. Be thorough but constructive in your feedback.

reviews:
profile: "chill"
request_changes_workflow: false
high_level_summary: true
poem: true
review_status: true
auto_review:
enabled: true
drafts: false
base_branches: ["main", "dev"]
path_instructions:
- path: "app/src/**/*.{ts,tsx,js,jsx}"
instructions: |
Review React Native TypeScript code for:
- Component architecture and reusability
- State management patterns
- Performance optimizations
- TypeScript type safety
- React hooks usage and dependencies
- Navigation patterns
- path: "contracts/**/*.sol"
instructions: |
Review Solidity smart contracts for:
- Security vulnerabilities (reentrancy, overflow, etc.)
- Gas optimization opportunities
- Access control patterns
- Event emission for important state changes
- Code documentation and NatSpec comments
- path: "circuits/**/*.circom"
instructions: |
Review ZK circuit code for:
- Circuit correctness and completeness
- Constraint efficiency
- Input validation
- Security considerations for zero-knowledge proofs
- path: "**/*.{test,spec}.{ts,js,tsx,jsx}"
instructions: |
Review test files for:
- Test coverage completeness
- Test case quality and edge cases
- Mock usage appropriateness
- Test readability and maintainability
- path: "app/android/**/*"
instructions: |
Review Android-specific code for:
- Platform-specific implementations
- Performance considerations
- Security best practices for mobile
- path: "app/ios/**/*"
instructions: |
Review iOS-specific code for:
- Platform-specific implementations
- Performance considerations
- Security best practices for mobile

chat:
auto_reply: true
16 changes: 16 additions & 0 deletions .github/workflows/block-non-dev-to-main.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
name: Block non-dev PRs to main

on:
pull_request:
branches: [main]

jobs:
check-source:
runs-on: ubuntu-latest
steps:
- name: Block PRs not from dev
run: |
if [[ "${{ github.head_ref }}" != "dev" ]]; then
echo "You can only merge from dev to main."
exit 1
fi
Comment on lines +11 to +16
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue

Security: Avoid direct use of potentially untrusted input in shell scripts.

Using ${{ github.head_ref }} directly in shell scripts poses a security risk as it can contain malicious commands. Use an environment variable instead.

Apply this diff to fix the security vulnerability:

-      - name: Block PRs not from dev
-        run: |
-          if [[ "${{ github.head_ref }}" != "dev" ]]; then
-            echo "You can only merge from dev to main."
-            exit 1
-          fi
+      - name: Block PRs not from dev
+        env:
+          HEAD_REF: ${{ github.head_ref }}
+        run: |
+          if [[ "$HEAD_REF" != "dev" ]]; then
+            echo "You can only merge from dev to main."
+            exit 1
+          fi
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
- name: Block PRs not from dev
run: |
if [[ "${{ github.head_ref }}" != "dev" ]]; then
echo "You can only merge from dev to main."
exit 1
fi
- name: Block PRs not from dev
env:
HEAD_REF: ${{ github.head_ref }}
run: |
if [[ "$HEAD_REF" != "dev" ]]; then
echo "You can only merge from dev to main."
exit 1
fi
🧰 Tools
🪛 actionlint (1.7.7)

12-12: "github.head_ref" is potentially untrusted. avoid using it directly in inline scripts. instead, pass it through an environment variable. see https://docs.github.com/en/actions/security-for-github-actions/security-guides/security-hardening-for-github-actions for more details

(expression)

🤖 Prompt for AI Agents
In .github/workflows/block-non-dev-to-main.yml around lines 11 to 16, avoid
using the GitHub context expression ${{ github.head_ref }} directly in the shell
script. Instead, assign it to an environment variable in the workflow step and
reference that variable in the shell script to prevent potential command
injection vulnerabilities.

14 changes: 11 additions & 3 deletions .github/workflows/npm-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,12 @@ name: Publish to npm
on:
push:
branches:
- main
- dev
paths:
- 'sdk/core/package.json'
- 'sdk/qrcode/package.json'
- 'common/package.json'
workflow_dispatch:

jobs:
detect-changes:
Expand Down Expand Up @@ -46,7 +47,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Set up Node.js
uses: actions/setup-node@v4
with:
Expand All @@ -55,6 +56,10 @@ jobs:

- name: Install Dependencies
uses: ./.github/actions/yarn-install

- run: |
yarn config set npmScopes.selfxyz.npmAuthToken ${{ secrets.NPM_AUTH_TOKEN }}
yarn config set npmPublishAccess public

- name: Build package
run: |
Expand All @@ -66,6 +71,7 @@ jobs:
yarn npm publish --access public
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
NPM_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

publish-qrcode:
needs: detect-changes
Expand All @@ -85,14 +91,15 @@ jobs:

- name: Build package
run: |
yarn workspace @sdk/qrcode build:deps
yarn workspace @selfxyz/qrcode build:deps

- name: Publish to npm
working-directory: sdk/qrcode
run: |
yarn npm publish --access public
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
NPM_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

publish-common:
needs: detect-changes
Expand All @@ -119,3 +126,4 @@ jobs:
yarn npm publish --access public
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
NPM_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
23 changes: 3 additions & 20 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -1,21 +1,4 @@
MIT License
This repository contains multiple packages, each with its own LICENSE file.
Refer to the LICENSE file in each package directory for the terms that govern
that package.

Copyright (c) 2023 Proof of Passport

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.
2 changes: 2 additions & 0 deletions app/App.tsx
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// SPDX-License-Identifier: BUSL-1.1; Copyright (c) 2025 Social Connect Labs, Inc.; Licensed under BUSL-1.1 (see LICENSE); Apache-2.0 from 2029-06-11

import 'react-native-get-random-values';

import { Buffer } from 'buffer';
Expand Down
35 changes: 35 additions & 0 deletions app/LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
Business Source License 1.1

Parameters

Licensor: Social Connect Labs, Inc.

Licensed Work: The code in this folder and all folders nested within it, including all files and components unless explicitly stated otherwise.

Additional Use Grant: Any use for development, testing, and deployment on networks approved by Social Connect Labs, Inc., including internal business operations and academic research.

Change Date: 2029-06-11

Change License: Apache License, Version 2.0

================================================================

Business Source License 1.1

Copyright (C) 2025 Social Connect Labs, Inc.

The contents of this repository are licensed under the Business Source License 1.1 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at:

https://spdx.org/licenses/BUSL-1.1.html

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.

Change Date

The Change Date is the later of four years from the date this repository was published or 2029-06-11.

Change License

On the Change Date, the contents of this repository will be made available under the terms of the Apache License, Version 2.0, as published by the Apache Software Foundation.

See the License for the specific language governing permissions and limitations under the Business Source License.
4 changes: 1 addition & 3 deletions app/android/android-passport-reader/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ dependencies {
implementation 'commons-codec:commons-codec:1.13'

//Camera
implementation "com.github.RedApparat:Fotoapparat:2.7.0"
implementation "com.github.fotoapparat:fotoapparat:2.7.0"

implementation 'androidx.multidex:multidex:2.0.1'

Expand All @@ -98,5 +98,3 @@ dependencies {
implementation 'com.squareup.retrofit2:converter-gson:2.9.0'
implementation 'com.squareup.retrofit2:adapter-rxjava2:2.9.0'
}


6 changes: 3 additions & 3 deletions app/android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -86,8 +86,8 @@ android {
applicationId "com.proofofpassportapp"
minSdkVersion rootProject.ext.minSdkVersion
targetSdkVersion rootProject.ext.targetSdkVersion
versionCode 69
versionName "2.5.3"
versionCode 73
versionName "2.5.4"
externalNativeBuild {
cmake {
cppFlags += "-fexceptions -frtti -std=c++11"
Expand Down Expand Up @@ -160,7 +160,7 @@ dependencies {
implementation 'com.google.android.gms:play-services-mlkit-text-recognition-common:19.1.0'
implementation 'io.reactivex.rxjava2:rxandroid:2.1.1'
implementation 'io.reactivex.rxjava2:rxjava:2.2.21'
implementation "com.github.RedApparat:Fotoapparat:2.7.0"
implementation "com.github.fotoapparat:fotoapparat:2.7.0"

implementation "androidx.concurrent:concurrent-futures:1.1.0"
implementation "com.google.guava:guava:31.1-android"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// SPDX-License-Identifier: BUSL-1.1; Copyright (c) 2025 Social Connect Labs, Inc.; Licensed under BUSL-1.1 (see LICENSE); Apache-2.0 from 2029-06-11

package com.proofofpassportapp

import android.app.backup.BackupManager
Expand All @@ -22,4 +24,4 @@ class BackupModule(reactContext: ReactApplicationContext): ReactContextBaseJavaM
// https://developer.android.com/identity/data/keyvaluebackup#RequestingRestore
promise.resolve(null)
}
}
}
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// SPDX-License-Identifier: BUSL-1.1; Copyright (c) 2025 Social Connect Labs, Inc.; Licensed under BUSL-1.1 (see LICENSE); Apache-2.0 from 2029-06-11

package com.proofofpassportapp

import com.facebook.react.ReactPackage
Expand All @@ -16,4 +18,4 @@ class BackupPackage : ReactPackage {
)
}

}
}
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// SPDX-License-Identifier: BUSL-1.1; Copyright (c) 2025 Social Connect Labs, Inc.; Licensed under BUSL-1.1 (see LICENSE); Apache-2.0 from 2029-06-11

package com.proofofpassportapp;

import static com.google.android.gms.common.util.CollectionUtils.listOf;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// SPDX-License-Identifier: BUSL-1.1; Copyright (c) 2025 Social Connect Labs, Inc.; Licensed under BUSL-1.1 (see LICENSE); Apache-2.0 from 2029-06-11

package com.proofofpassportapp

import android.content.Intent
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// SPDX-License-Identifier: BUSL-1.1; Copyright (c) 2025 Social Connect Labs, Inc.; Licensed under BUSL-1.1 (see LICENSE); Apache-2.0 from 2029-06-11

package com.proofofpassportapp

import android.app.Application
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// SPDX-License-Identifier: BUSL-1.1; Copyright (c) 2025 Social Connect Labs, Inc.; Licensed under BUSL-1.1 (see LICENSE); Apache-2.0 from 2029-06-11

package com.proofofpassportapp;

import android.app.Activity;
Expand Down Expand Up @@ -90,4 +92,4 @@ public void onRequestPermissionsResult(int requestCode, String[] permissions, in
}
}
}
}
}
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// SPDX-License-Identifier: BUSL-1.1; Copyright (c) 2025 Social Connect Labs, Inc.; Licensed under BUSL-1.1 (see LICENSE); Apache-2.0 from 2029-06-11

package com.proofofpassportapp;

import com.facebook.react.ReactPackage;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// SPDX-License-Identifier: BUSL-1.1; Copyright (c) 2025 Social Connect Labs, Inc.; Licensed under BUSL-1.1 (see LICENSE); Apache-2.0 from 2029-06-11

/*
* Copyright 2017 The Android Open Source Project
*
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// SPDX-License-Identifier: BUSL-1.1; Copyright (c) 2025 Social Connect Labs, Inc.; Licensed under BUSL-1.1 (see LICENSE); Apache-2.0 from 2029-06-11

package com.proofofpassportapp.ui

import android.view.Choreographer
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// SPDX-License-Identifier: BUSL-1.1; Copyright (c) 2025 Social Connect Labs, Inc.; Licensed under BUSL-1.1 (see LICENSE); Apache-2.0 from 2029-06-11

package com.proofofpassportapp.ui

import android.view.Choreographer
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// SPDX-License-Identifier: BUSL-1.1; Copyright (c) 2025 Social Connect Labs, Inc.; Licensed under BUSL-1.1 (see LICENSE); Apache-2.0 from 2029-06-11

/*
* Copyright 2017 The Android Open Source Project
*
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// SPDX-License-Identifier: BUSL-1.1; Copyright (c) 2025 Social Connect Labs, Inc.; Licensed under BUSL-1.1 (see LICENSE); Apache-2.0 from 2029-06-11

// Copyright 2018 Google LLC
//
// Licensed under the Apache License, Version 2.0 (the "License");
Expand Down
7 changes: 2 additions & 5 deletions app/android/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -36,22 +36,19 @@ allprojects {
repositories {
google()
mavenCentral()
jcenter()
maven {
url("$rootDir/../../node_modules/react-native/android")
}
maven {
url("$rootDir/../../node_modules/jsc-android/dist")
}
maven { url 'https://jitpack.io' }
jcenter()
maven {
url 'https://google.bintray.com/google-services'
}
}
configurations.configureEach {
resolutionStrategy.dependencySubstitution {
substitute(platform(module('com.gemalto.jp2:jp2-android'))) using module('com.github.Tgo1014:JP2ForAndroid:1.0.4')
substitute module('io.fotoapparat:fotoapparat') using module('com.github.RedApparat:Fotoapparat:2.7.0')
substitute module('io.fotoapparat:fotoapparat') using module('com.github.fotoapparat:fotoapparat:2.7.0')
}
resolutionStrategy.force 'com.google.guava:listenablefuture:9999.0-empty-to-avoid-conflict-with-guava'
}
Expand Down
16 changes: 14 additions & 2 deletions app/android/gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,13 @@
# Specifies the JVM arguments used for the daemon process.
# The setting is particularly useful for tweaking memory settings.
# Default value: -Xmx512m -XX:MaxMetaspaceSize=256m
org.gradle.jvmargs=-Xmx2048m -XX:MaxMetaspaceSize=512m
org.gradle.jvmargs=-Xmx4096m -XX:MaxMetaspaceSize=512m -XX:+HeapDumpOnOutOfMemoryError -Dfile.encoding=UTF-8 -XX:+UseParallelGC
android.defaults.buildfeatures.buildconfig=true

# When configured, Gradle will run in incubating parallel mode.
# This option should only be used with decoupled projects. More details, visit
# http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
# org.gradle.parallel=true
org.gradle.parallel=true

# AndroidX package structure to make it clearer which packages are bundled with the
# Android operating system, and which are packaged with your app's APK
Expand Down Expand Up @@ -44,3 +44,15 @@ newArchEnabled=false
hermesEnabled=true

android.jetifier.ignorelist=bcprov-jdk18on

# Additional Gradle optimizations for better build performance
org.gradle.caching=true
org.gradle.configureondemand=true

# Better dependency caching and offline support
org.gradle.dependency.verification=off
# Uncomment the next line when you want to work completely offline
# org.gradle.offline=true

# Suppress SDK version warnings for better build experience
android.suppressUnsupportedCompileSdk=35
Loading
Loading