Skip to content

Commit 08ea94e

Browse files
committed
Begin version patching mechanism
1 parent 609671c commit 08ea94e

21 files changed

+77
-26
lines changed

docs/notes/command_surface.md

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,11 @@ The `CLA` class byte is usually `00`, `80`, `B0`, or any of these `| 10` .
77
Standard ISO commands:
88

99
- `C0`: GET RESPONSE
10-
- `A4`: SELECT
10+
- `A4`: SELECT
11+
12+
Vivokey extension:
13+
14+
- `F4`: GET VERSION
1115

1216
## apex-fido2, FIDO2Applet, and u2f-javacard
1317

@@ -192,4 +196,4 @@ Keycard commands:
192196
- `C1`: SET PINLESS PATH
193197
- `C2`: EXPORT KEY
194198
- `CA`: GET DATA
195-
- `E2`: STORE DATA
199+
- `E2`: STORE DATA

scripts/compile-all.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ for i in compile/*.sh; do
1313
echo "Skipping $i"
1414
fi
1515
if [ "$?" != 0 ]; then
16+
echo "Failed to compile $i"
1617
FAIL=1
1718
fi
1819
done

scripts/compile/FIDO2Applet.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
source "${0%/*}/res/compile.sh"
44

55
prepare_build FIDO2Applet
6+
patch_version $BUILD/src/main/java/us/q3q/fido2/FIDO2Applet.java
67
cd $BUILD
78
JC_HOME=/app/sdks/jc304_kit ./gradlew -PPackageID=A0000006472F0001 -PApplicationID=A0000006472F000101 buildJavaCard classes
89
cp $BUILD/build/javacard/*.cap /app/src/bin/

scripts/compile/SatochipApplet.sh

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,5 +3,6 @@
33
source "${0%/*}/res/compile.sh"
44

55
prepare_build SatochipApplet
6-
cp /app/src/scripts/compile/res/SatochipApplet.build.xml $BUILD
7-
JC_HOME=/app/sdks/jc304_kit build_default -buildfile SatochipApplet.build.xml
6+
patch_version $BUILD/src/org/satochip/applet/CardEdge.java
7+
cp -f /app/src/scripts/compile/res/SatochipApplet.build.xml $BUILD/build.xml
8+
JC_HOME=/app/sdks/jc304_kit build_default

scripts/compile/Satodime-Applet.sh

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,5 +3,6 @@
33
source "${0%/*}/res/compile.sh"
44

55
prepare_build Satodime-Applet
6-
cp /app/src/scripts/compile/res/Satodime-Applet.build.xml $BUILD
7-
JC_HOME=/app/sdks/jc304_kit build_default -buildfile Satodime-Applet.build.xml
6+
patch_version $BUILD/src/org/satodime/applet/Satodime.java
7+
cp /app/src/scripts/compile/res/Satodime-Applet.build.xml $BUILD/build.xml
8+
JC_HOME=/app/sdks/jc304_kit build_default

scripts/compile/Seedkeeper-Applet.sh

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,5 +3,6 @@
33
source "${0%/*}/res/compile.sh"
44

55
prepare_build Seedkeeper-Applet
6-
cp /app/src/scripts/compile/res/Seedkeeper-Applet.build.xml $BUILD
7-
JC_HOME=/app/sdks/jc304_kit build_default -buildfile Seedkeeper-Applet.build.xml
6+
patch_version $BUILD/src/org/seedkeeper/applet/SeedKeeper.java
7+
cp /app/src/scripts/compile/res/Seedkeeper-Applet.build.xml $BUILD/build.xml
8+
JC_HOME=/app/sdks/jc304_kit build_default

scripts/compile/SmartPGP.sh

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,5 +3,6 @@
33
source "${0%/*}/res/compile.sh"
44

55
prepare_build SmartPGP
6-
cp /app/src/scripts/compile/res/SmartPGP.build.xml $BUILD
7-
JC_HOME=/app/sdks/jc304_kit build_default -buildfile SmartPGP.build.xml
6+
patch_version $BUILD/src/fr/anssi/smartpgp/SmartPGPApplet.java
7+
cp /app/src/scripts/compile/res/SmartPGP.build.xml $BUILD/build.xml
8+
JC_HOME=/app/sdks/jc304_kit build_default

scripts/compile/apex-fido2.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,5 @@
33
source "${0%/*}/res/compile.sh"
44

55
prepare_build apex-fido2
6+
patch_version $BUILD/src/main/java/com/vivokey/fido2/Dispatcher.java
67
JC_HOME=/app/sdks/jc305u3_kit build_default

scripts/compile/apex-ndef.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,5 @@
33
source "${0%/*}/res/compile.sh"
44

55
prepare_build apex-ndef
6+
patch_version $BUILD/src/main/java/com/vivokey/ndef/NDEF.java
67
JC_HOME=/app/sdks/jc305u3_kit build_default

scripts/compile/apex-spark.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,5 @@
33
source "${0%/*}/res/compile.sh"
44

55
prepare_build apex-spark
6+
patch_version $BUILD/src/com/vivokey/spark/Spark2.java
67
JC_HOME=/app/sdks/jc305u3_kit build_default

0 commit comments

Comments
 (0)