M
maniac205
Ambitioniertes Mitglied
- 10
Hallo,
ich programmiere derzeit eine App die ein PKCS12 File in einen KeyStore laden soll.
Soweit funktioniert auch alles.
Nur bekomme ich in der LogCat die Meldung "GC_CONCURRENT..." was hat es mit dieser auf sich? Lässt sich das Problem umgehen?
Die Ladezeit kann sich noch verbessern, da ich derzeit den Emulator benutze. Auf Android 4.0.4.
Hier noch die LogCat und Code Beispiele:
LogCat:
Android/Java:
ich programmiere derzeit eine App die ein PKCS12 File in einen KeyStore laden soll.
Soweit funktioniert auch alles.
Nur bekomme ich in der LogCat die Meldung "GC_CONCURRENT..." was hat es mit dieser auf sich? Lässt sich das Problem umgehen?
Die Ladezeit kann sich noch verbessern, da ich derzeit den Emulator benutze. Auf Android 4.0.4.
Hier noch die LogCat und Code Beispiele:
LogCat:
Code:
05-15 12:14:12.427: D/CertHelper.loadCertIntoKeyStore (String path, String passwort)(13408): fileIn.getAbsolutePath(): = /data/data/andro4.test.fhg/app_certdir/Contacts_Android.pfx
05-15 12:14:12.865: D/dalvikvm(13408): GC_CONCURRENT freed 202K, 3% free 12812K/13127K, paused 7ms+6ms
05-15 12:16:28.704: D/CertHelper.loadCertIntoKeyStore (String path, String passwort)(13408): PKCS12 in KeyStore
Android/Java:
Code:
public void loadCertIntoKeyStore(String filePath, String passwort)
throws IOException, NoSuchAlgorithmException, CertificateException {
String tag = "CertHelper.loadCertIntoKeyStore (String path, String passwort)";
char[] charArrayPasswort = passwort.toCharArray();
File fileIn = new File(filePath);
Log.d(tag, "fileIn.getAbsolutePath(): = " + fileIn.getAbsolutePath());
if (!fileIn.canRead()) {
Log.e(tag, "File kann nicht gelesen werden! - " + filePath);
throw new IOException("Can't read File!");
}
pkcs12ks.load(new FileInputStream(fileIn), charArrayPasswort);
Log.d(tag, "PKCS12 in KeyStore");
}
Zuletzt bearbeitet: