YehudaKremer / msix

Create Msix installer for flutter windows-build files.
https://pub.dev/packages/msix
MIT License
280 stars 69 forks source link

[BUG] Certificate Details can't be read #60

Closed j0chn1 closed 2 years ago

j0chn1 commented 3 years ago

:information_source: Info

Version: 2.5.2

:speech_balloon: Description

When creating the msix the certificate details cannot be read: C:\Users\Administrator\IdeaProjects\flutter\nextloud_password_client>flutter build windows Building with sound null safety Building Windows application... C:\Users\Administrator\IdeaProjects\flutter\nextloud_password_client>flutter pub run msix:create ☑ parsing cli arguments ☑ validating config values ☑ cleaning temporary files ☑ copying assets folder ☑ creating app icons folder ☑ copying app icons ☑ copying VC libraries [❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚] 50% getting certificate publisher.. Fail to read the certificate details, please check if the certificate is valid and the password is correct

:scroll: Pubspec.yaml

name: nextcloud_password_client description: A desktop client to manage your passwords within the Nextcloud password app.

publish_to: 'none' CoreFoundationKeys.html version: 0.1.0+1

environment: sdk: ">=2.12.0 <3.0.0"

dependencies: flutter: sdk: flutter flutter_localizations: sdk: flutter
intl: ^0.17.0 http: ^0.13.3 path_provider: ^2.0.2 provider: ^6.0.0 libsodium: ^0.2.0 flutter_sodium: ^0.2.0 multi_split_view: ^1.7.1 flutter_secure_storage: ^5.0.0-beta.5 hive: ^2.0.4 hive_flutter: ^1.1.0 flutter_simple_treeview: ^3.0.0-nullsafety.1 pluto_grid: ^2.5.0 url_launcher: ^6.0.12 msix: ^2.5.2

dev_dependencies: flutter_test: sdk: flutter build_runner: ^2.0.3 hive_generator: ^1.1.1 lints: ^1.0.1 flutter_lints: ^1.0.4

flutter: uses-material-design: true generate: true

YehudaKremer commented 3 years ago

Hello @j0chn1 i added useful error logs to version 2.5.3 can you please upgrade, run and paste again the same details

thank you

j0chn1 commented 3 years ago

Hello @YehudaKremer , unfortunately I have no time today. I will test it tomorrow evening (timezone: met)

j0chn1 commented 2 years ago

Hello @YehudaKremer, I was able to do so today: C:\Users\Administrator\IdeaProjects\flutter\nextloud_password_client>flutter pub run msix:create ☑ parsing cli arguments ☑ validating config values ☑ cleaning temporary files ☑ copying assets folder ☑ creating app icons folder ☑ copying app icons ☑ copying VC libraries [❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚] 50% getting certificate publisher.. Bad state: No element

0 ListMixin.firstWhere (dart:collection/list.dart:167:5)

1 Signtool.getCertificatePublisher (package:msix/src/cli/signtool.dart:32:12)

2 Msix.createMsix (package:msix/msix.dart:29:16)

☑ getting certificate publisher [❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚] 57% generate appx manifest.. Unhandled exception: Null check operator used on a null value #0 Manifest.generateAppxManifest (package:msix/src/manifest.dart:38:45) #1 Msix.createMsix (package:msix/msix.dart:31:17) pub finished with exit code 255
YehudaKremer commented 2 years ago

great thank you

can you please try again with version 2.5.4 and paste here the log output (i added fix + log)

again, thank you for your time and effort

j0chn1 commented 2 years ago

Hey @YehudaKremer , please check the output. And I have to thank you for your work on this plugin ;-)

C:\Users\Administrator\IdeaProjects\flutter\nextloud_password_client>flutter pub run msix:create ☑ parsing cli arguments ☑ validating config values ☑ cleaning temporary files ☑ copying assets folder ☑ creating app icons folder ☑ copying app icons ☑ copying VC libraries [❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚❚] 50% getting certificate publisher.. Certificate Details: ================ Zertifikat 0 ================ =========== Verschachtelungsebene 1 anfangen ========== Element 0: Seriennummer: 7178ac643ca913493433024faa228602173e13db Aussteller: CN=Msix Testing, O=Msix Testing Corporation, S=Some-State, C=US Nicht vor: 19.10.2021 16:57 Nicht nach: 03.08.2295 16:57 Antragsteller: CN=Msix Testing, O=Msix Testing Corporation, S=Some-State, C=US Signatur stimmt mit dem öffentlichen Schlüssel überein. Stammzertifikat: Antragsteller stimmt mit Aussteller überein Zertifikathash(sha1): 028bc9922d198ee83d776aa19cb8e82897691e0c ---------- Verschachtelungsebene 1 beenden ---------- Anbieter = Microsoft Enhanced Cryptographic Provider v1.0 Verschlüsselungstest wurde durchgeführt CertUtil: -dump-Befehl wurde erfolgreich ausgeführt.

Bad state: No element

0 ListMixin.firstWhere (dart:collection/list.dart:167:5)

1 Signtool.getCertificatePublisher (package:msix/src/cli/signtool.dart:34:12)

2 Msix.createMsix (package:msix/msix.dart:29:16)

YehudaKremer commented 2 years ago

OK! the reason for this bug is the certificate details is written in the OS language and i thought is always in English, i publish a fix 2.5.5, please try it up, hope it will work this time

thanks

j0chn1 commented 2 years ago

Thank you for the fix. I was able to create the msix and install it with powershell. Thank alot for your work!!!!!!