Closed rnrnstar2 closed 1 year ago
I may be wrong, but I think invalid padding could happen if the pubkey in tauri.conf.json is a file path and not the actual content of that file. Could you check that first please?
I used to set the signature code as is. I didn't set the file path. So I set pubkey and privatekey like below.
"updater": {
"active": true,
"dialog": true,
"endpoints": [
"https://tauri-updater.s3.ap-northeast-1.amazonaws.com/release_check.json"
],
"pubkey": "/Users/xxx/.tauri/myapp.key.pub"
},
export TAURI_PRIVATE_KEY="/Users/xxx/.tauri/myapp.key"
When I tried this, it changed to the following error.
Error Invalid byte 46, offset 16.
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
Error Invalid padding occurs when the actual content of that file is set as follows. export TAURI_PRIVATE_KEY="actual content of myapp.key"
the pubkey
should be the content of the file not a path to, which should solve the Error Invalid byte 46, offset 16
error. for TAURI_PRIVATE_KEY
env var, it is fine to use the path.
thank you for your response.
"updater": {
"active": true,
"dialog": true,
"endpoints": [
"https://tauri-updater.s3.ap-northeast-1.amazonaws.com/release_check.json"
],
"pubkey": "xxxxxxx_{myapp.key.pub content}_xxxxxx"
},
export TAURI_PRIVATE_KEY="xxxxxxx_{myapp.key content}_xxxxxx"
I tried setting the file contents like the code above, but I still get the Error Invalid padding
error.
try export TAURI_PRIVATE_KEY="/path/to/myapp.key"
- info Creating an optimized production build .. Compiling app v0.1.0 (/Users/rnrnstar/github/VolumeAchievementTool/apps/tradeclicker/src-tauri)
Finished release [optimized] target(s) in 7.48s
Bundling TradeClicker.app (/Users/rnrnstar/github/VolumeAchievementTool/apps/tradeclicker/src-tauri/target/release/bundle/macos/TradeClicker.app)
Bundling TradeClicker_1.0.0_aarch64.dmg (/Users/rnrnstar/github/VolumeAchievementTool/apps/tradeclicker/src-tauri/target/release/bundle/dmg/TradeClicker_1.0.0_aarch64.dmg)
Running bundle_dmg.sh
Error failed to bundle project: error running bundle_dmg.sh
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
I tried export TAURI_PRIVATE_KEY="/path/to/myapp.key"
I got this error.
The good news is that the updater is working, the bad new is that you hit https://github.com/tauri-apps/tauri/issues/3055 so I will go ahead close this issue.
The good news is that the updater is working, the bad new is that you hit #3055 so I will go ahead close this issue.
Hi, I'm having the same problem what did you do to make it work?
Compiling app v0.0.1 (D:\Developer\myapp\src-tauri)
Finished `release` profile [optimized] target(s) in 20.56s
Built application at: D:\Developer\myapp\src-tauri\target\release\app.exe
Info Target: x64
Running candle for "main.wxs"
Running light to produce D:\Developer\myapp\src-tauri\target\release\bundle\msi\apppku_0.0.1_x64_en-US.msi
Info Target: x64
Running makensis.exe to produce D:\Developer\myapp\src-tauri\target\release\bundle\nsis\apppku_0.0.1_x64-setup.exe
Warn The bundler was configured to create updater artifacts but no updater-enabled targets were built. Please enable one of these targets: app, appimage, msi, nsis
Finished 2 bundles at:
D:\Developer\myapp\src-tauri\target\release\bundle\msi\apppku_0.0.1_x64_en-US.msi
D:\Developer\myapp\src-tauri\target\release\bundle\nsis\apppku_0.0.1_x64-setup.exe
Error Invalid padding
Describe the bug
An error occurs when the updater's active is set to true. If false, complete successfully.
As per the document, I have created a signature, set bash environment variables, and set pubkey in tauri.conf.json.
What error is Error Invalid padding?
Reproduction
No response
Expected behavior
No response
Platform and versions
Stack trace
No response
Additional context
No response