Skip to content
Merged

Dev #1074

Show file tree
Hide file tree
Changes from 20 commits
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
3d46aec
chore: bump v2.6.5 rd2 (#1067)
transphorm Sep 13, 2025
657d8af
chore: update tooling dependencies (#1069)
transphorm Sep 14, 2025
5c569e6
chore: minor fixes across monorepo (#1068)
transphorm Sep 14, 2025
045a805
fix yarn build; add workflow ci (#1075)
transphorm Sep 16, 2025
8e385cb
feat: add functions for disclosing aadhaar attributes (#1033)
Nesopie Sep 16, 2025
c11c9af
chore: update monorepo artifacts (#1079)
transphorm Sep 16, 2025
f85a23a
cleans up unused parts of sdk interface, adds inline documentation, (…
aaronmgdr Sep 17, 2025
729ee76
Feat/aadhaar sdk (#1082)
Nesopie Sep 17, 2025
30cc43e
feat: change to gcp attestation verification (#959)
Nesopie Sep 17, 2025
8983ac2
Mobile SDK: move provingMachine from the app (#1052)
shazarre Sep 17, 2025
3397fcf
Revert "Mobile SDK: move provingMachine from the app (#1052)" (#1084)
transphorm Sep 17, 2025
48e4a53
fix: sdk (#1085)
Nesopie Sep 17, 2025
1d648ef
bump sdk (#1086)
Nesopie Sep 17, 2025
c2406f0
chore update mobile app types (#1087)
transphorm Sep 18, 2025
a0123d2
feat: add contract utils (#1088)
Nesopie Sep 18, 2025
86c595b
Feat/contracts npm publish (#1089)
Nesopie Sep 18, 2025
b21df03
fix: use celo sepolia in common (#1091)
Nesopie Sep 18, 2025
b0ae194
chore: export selfappbuilder (#1092)
Nesopie Sep 18, 2025
a005bde
[SELF-747] feat: clone android passport reader during setup (#1080)
transphorm Sep 18, 2025
779fea5
address version mismatches and package resolutions (#1081)
transphorm Sep 19, 2025
d0a66a1
fix: aadhaar verifier abi (#1096)
Nesopie Sep 19, 2025
664be08
fix: go-sdk (#1090)
Vishalkulkarni45 Sep 19, 2025
2df4dc4
SELF-725: add iOS qrcode opener and aadhaar screen (#1038)
remicolin Sep 20, 2025
48a8146
fix aadhaar screen test (#1101)
transphorm Sep 20, 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
161 changes: 0 additions & 161 deletions .cursor/rules/technical-specification.mdc

This file was deleted.

5 changes: 3 additions & 2 deletions .cursorignore
Original file line number Diff line number Diff line change
Expand Up @@ -191,8 +191,6 @@ circuits/tests/**/test_cases.ts

# iOS
*.xcworkspace/
*.xcodeproj/
*.pbxproj
app/ios/App Thinning Size Report.txt

# Android
Expand Down Expand Up @@ -278,6 +276,9 @@ circuits/ptau/
!**/*.sol
!**/*.circom

# Exception for specific private module setup script
!app/scripts/setup-private-modules.cjs

# But exclude generated TypeScript declaration files
**/*.d.ts
!**/types/*.d.ts
Expand Down
20 changes: 0 additions & 20 deletions .cursorrules
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,6 @@
## Core Workflows

1. Document Verification Flow
- NFC chip data extraction and validation
- Zero-knowledge proof generation for privacy
- Multi-stage attestation verification
- Cross-chain verification support
Expand Down Expand Up @@ -128,25 +127,6 @@ This is a React Native identity verification app with NFC passport reading, zero
- Test utilities in `tests/__setup__/databaseMocks.ts`
- Mock database instance for testing

## NFC Implementation

### Cross-Platform Architecture
- iOS: Custom PassportReader Swift module
- Android: Custom RNPassportReaderModule Kotlin implementation
- Unified JavaScript interface with platform detection

### Authentication Methods
- MRZ Key: Derived from passport number, DOB, and expiry date
- CAN (Card Access Number): 6-digit number for PACE authentication
- PACE: Password Authenticated Connection Establishment
- BAC fallback when PACE fails

### Error Handling
- Multiple BAC attempts with delays
- Graceful degradation from PACE to BAC
- Real-time status updates and haptic feedback
- Comprehensive error boundaries

## Code Organization

### File Structure
Expand Down
50 changes: 50 additions & 0 deletions .github/actions/clone-android-passport-reader/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
name: Clone android-passport-reader
description: "Clones the android-passport-reader repository if it does not exist"

inputs:
working_directory:
description: "Working directory path (where android/ subdirectory is located)"
required: false
default: "."
selfxyz_internal_pat:
description: "SELFXYZ internal repository PAT for private repository access"
required: false

runs:
using: "composite"
steps:
- name: Clone android-passport-reader
shell: bash
run: |
set -euo pipefail
# Check if PAT is available for private module cloning
if [ -z "${{ inputs.selfxyz_internal_pat }}" ]; then
echo "🔒 Skipping private module cloning (no PAT provided)"
echo "ℹ️ This is expected for forked PRs - build will continue without private modules"
exit 0
fi

cd "${{ inputs.working_directory }}"

if [ ! -d "android/android-passport-reader" ]; then
echo "📦 Cloning android-passport-reader for build..."
cd android

# Clone using PAT (embed temporarily, then scrub)
if git clone --depth 1 --quiet "https://${{ inputs.selfxyz_internal_pat }}@github.com/selfxyz/android-passport-reader.git"; then
echo "✅ android-passport-reader cloned successfully"
# Immediately scrub the credential from remote URL for security
git -C android-passport-reader remote set-url origin https://github.com/selfxyz/android-passport-reader.git || true
else
echo "❌ Failed to clone android-passport-reader"
echo "Please ensure a valid SELFXYZ internal PAT is provided to this action"
exit 1
fi
elif [ "$CI" = "true" ]; then
echo "⚠️ android-passport-reader exists in CI - this is unexpected"
echo "📁 Directory contents:"
ls -la android/android-passport-reader/ || true
else
echo "📁 android-passport-reader already exists - preserving existing directory"
echo "ℹ️ Local development environment detected - your changes are safe"
fi
10 changes: 5 additions & 5 deletions .github/actions/mobile-setup/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -78,12 +78,12 @@ runs:
fi

# Run mobile-specific installation
if [[ "${{ runner.os }}" == "macOS" ]]; then
yarn install-app:mobile-deploy:ios
else
yarn install-app:mobile-deploy
fi
yarn install-app:mobile-deploy

- name: Install Ruby dependencies
shell: bash
run: |
cd ${{ inputs.app_path }}
# Install Ruby gems with bundler (respecting cache)
echo "📦 Installing Ruby gems with strict lock file..."
if ! bundle install --jobs 4 --retry 3; then
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/mobile-bundle-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ on:

jobs:
analyze-android:
runs-on: macos-14
runs-on: macos-latest-large
steps:
- uses: actions/checkout@v4
- name: Read and sanitize Node.js version
Expand Down Expand Up @@ -80,7 +80,7 @@ jobs:
working-directory: ./app

analyze-ios:
runs-on: macos-14
runs-on: macos-latest-large
steps:
- uses: actions/checkout@v4
- name: Read and sanitize Node.js version
Expand Down
9 changes: 9 additions & 0 deletions .github/workflows/mobile-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ concurrency:
jobs:
build-deps:
runs-on: macos-latest-large
timeout-minutes: 60
steps:
- uses: actions/checkout@v4
- name: Read and sanitize Node.js version
Expand Down Expand Up @@ -92,6 +93,7 @@ jobs:
test:
runs-on: macos-latest-large
needs: build-deps
timeout-minutes: 60
steps:
- uses: actions/checkout@v4
- name: Read and sanitize Node.js version
Expand Down Expand Up @@ -193,6 +195,7 @@ jobs:
build-ios:
runs-on: macos-latest-large
needs: build-deps
timeout-minutes: 60
env:
# iOS project configuration - hardcoded for CI stability
IOS_PROJECT_NAME: "Self"
Expand Down Expand Up @@ -381,6 +384,7 @@ jobs:
build-android:
runs-on: ubuntu-latest
needs: build-deps
timeout-minutes: 60
steps:
- uses: actions/checkout@v4
- name: Read and sanitize Node.js version
Expand Down Expand Up @@ -444,6 +448,11 @@ jobs:
run: |
echo "Cache miss for built dependencies. Building now..."
yarn workspace @selfxyz/mobile-app run build:deps
- name: Clone android-passport-reader
uses: ./.github/actions/clone-android-passport-reader
with:
working_directory: ${{ env.APP_PATH }}
selfxyz_internal_pat: ${{ secrets.SELFXYZ_INTERNAL_REPO_PAT }}
- name: Build Android (with AAPT2 symlink fix)
run: yarn android:ci
working-directory: ./app
25 changes: 23 additions & 2 deletions .github/workflows/mobile-deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -223,8 +223,19 @@ jobs:

echo "✅ Lock files exist"

- name: Install Mobile Dependencies
if: inputs.platform != 'android'
- name: Install Mobile Dependencies (main repo)
if: inputs.platform != 'android' && (github.event_name != 'pull_request' || github.event.pull_request.head.repo.fork == false)
uses: ./.github/actions/mobile-setup
with:
app_path: ${{ env.APP_PATH }}
node_version: ${{ env.NODE_VERSION }}
ruby_version: ${{ env.RUBY_VERSION }}
workspace: ${{ env.WORKSPACE }}
env:
SELFXYZ_INTERNAL_REPO_PAT: ${{ secrets.SELFXYZ_INTERNAL_REPO_PAT }}

- name: Install Mobile Dependencies (forked PRs - no secrets)
if: inputs.platform != 'android' && github.event_name == 'pull_request' && github.event.pull_request.head.repo.fork == true
uses: ./.github/actions/mobile-setup
with:
app_path: ${{ env.APP_PATH }}
Expand Down Expand Up @@ -774,6 +785,9 @@ jobs:
node_version: ${{ env.NODE_VERSION }}
ruby_version: ${{ env.RUBY_VERSION }}
workspace: ${{ env.WORKSPACE }}
env:
SELFXYZ_INTERNAL_REPO_PAT: ${{ secrets.SELFXYZ_INTERNAL_REPO_PAT }}
PLATFORM: ${{ inputs.platform }}

# android specific steps

Expand Down Expand Up @@ -840,6 +854,13 @@ jobs:
python -m pip install --upgrade pip
pip install google-auth google-auth-oauthlib google-auth-httplib2 google-api-python-client

- name: Clone android-passport-reader
if: inputs.platform != 'ios'
uses: ./.github/actions/clone-android-passport-reader
with:
working_directory: ${{ env.APP_PATH }}
selfxyz_internal_pat: ${{ secrets.SELFXYZ_INTERNAL_REPO_PAT }}

- name: Build Dependencies (Android)
if: inputs.platform != 'ios'
run: |
Expand Down
Loading
Loading