New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

File is encrypted or is not a database error #205

Closed
arden opened this Issue Mar 11, 2017 · 10 comments

Comments

Projects
None yet
4 participants
@arden

arden commented Mar 11, 2017

i have a ios app
run app in iphone's simulator that work ok.
but run app in iphone mobile that work error: File is encrypted or is not a database error

@developernotes

This comment has been minimized.

Show comment
Hide comment
@developernotes

developernotes Mar 13, 2017

Member

Hello @arden

A few follow up questions:

  • Are you certain you are providing the correct password to the database?
  • Does the database exist?
  • Is the database encrypted with SQLCipher already?
  • Are you able to debug the application on the device through Xcode?
  • What version of SQLCipher are you using?
  • What does PRAGMA cipher_version; report when you run it?
Member

developernotes commented Mar 13, 2017

Hello @arden

A few follow up questions:

  • Are you certain you are providing the correct password to the database?
  • Does the database exist?
  • Is the database encrypted with SQLCipher already?
  • Are you able to debug the application on the device through Xcode?
  • What version of SQLCipher are you using?
  • What does PRAGMA cipher_version; report when you run it?
@njafei

This comment has been minimized.

Show comment
Hide comment
@njafei

njafei Apr 26, 2017

@developernotes
I have the same question with this,here is my situation:

I try to open a file with sqlcipher

sqlcipher EnMicroMsg.db
sqlite> PRAGMA key = '2801209'; 
sqlite> create table a(id, int);

and i turn out an error: Error: file is encrypted or is not a database

but i can open the file with sqliteManager.

and PRAGMA cipher_version; report : 3.3.0

can u help me?

njafei commented Apr 26, 2017

@developernotes
I have the same question with this,here is my situation:

I try to open a file with sqlcipher

sqlcipher EnMicroMsg.db
sqlite> PRAGMA key = '2801209'; 
sqlite> create table a(id, int);

and i turn out an error: Error: file is encrypted or is not a database

but i can open the file with sqliteManager.

and PRAGMA cipher_version; report : 3.3.0

can u help me?

@developernotes

This comment has been minimized.

Show comment
Hide comment
@developernotes

developernotes Apr 26, 2017

Member

Hello @njafei

What version of SQLCipher was used to create the database file? Are you certain that is the correct password?

Member

developernotes commented Apr 26, 2017

Hello @njafei

What version of SQLCipher was used to create the database file? Are you certain that is the correct password?

@njafei

This comment has been minimized.

Show comment
Hide comment
@njafei

njafei Apr 27, 2017

@developernotes

I'm sure the password is correct,but not sure about the database file? how can I see the version of SQLCipher was used to create the database file? I have the file .

and I just update sqlcipher in my mac to V3.4.1, I think that the newest version, so could the reason be version?

njafei commented Apr 27, 2017

@developernotes

I'm sure the password is correct,but not sure about the database file? how can I see the version of SQLCipher was used to create the database file? I have the file .

and I just update sqlcipher in my mac to V3.4.1, I think that the newest version, so could the reason be version?

@developernotes

This comment has been minimized.

Show comment
Hide comment
@developernotes

developernotes Apr 27, 2017

Member

Hello @njafei

If you are able to execute code against the original version of the SQLCipher library that created the database, you will want to execute the following SQL command:

PRAGMA cipher_version;

What does your application report?

Member

developernotes commented Apr 27, 2017

Hello @njafei

If you are able to execute code against the original version of the SQLCipher library that created the database, you will want to execute the following SQL command:

PRAGMA cipher_version;

What does your application report?

@njafei

This comment has been minimized.

Show comment
Hide comment
@njafei

njafei Apr 28, 2017

@developernotes

application is using V3.5,but I can't find the V3.5 for mac os . is that the reason ?
I'm a little confused about the versions...

njafei commented Apr 28, 2017

@developernotes

application is using V3.5,but I can't find the V3.5 for mac os . is that the reason ?
I'm a little confused about the versions...

@developernotes

This comment has been minimized.

Show comment
Hide comment
@developernotes

developernotes Apr 28, 2017

Member

Hi @njafei

We have not released SQLCipher 3.5 on macOS. Are you developing an Android application on macOS by chance? Are you attempting to open an existing database and modify it, or are you creating a new database and modifying it?

Member

developernotes commented Apr 28, 2017

Hi @njafei

We have not released SQLCipher 3.5 on macOS. Are you developing an Android application on macOS by chance? Are you attempting to open an existing database and modify it, or are you creating a new database and modifying it?

@njafei

This comment has been minimized.

Show comment
Hide comment
@njafei

njafei May 2, 2017

@developernotes

My team is developing a Android application , they use SQLCipher 3.5 on it . And I'm trying to use the database file that application created, is that ok? and SQLCipher on mac is 3.4.1.

njafei commented May 2, 2017

@developernotes

My team is developing a Android application , they use SQLCipher 3.5 on it . And I'm trying to use the database file that application created, is that ok? and SQLCipher on mac is 3.4.1.

@developernotes

This comment has been minimized.

Show comment
Hide comment
@developernotes

developernotes May 2, 2017

Member

Hello @njafei

Yes, SQLCipher 3.4.1 on macOS will be able to read a SQLCipher database created using SQLCipher for Android 3.5. Note the latest version of SQLCipher for Android is 3.5.7.

Member

developernotes commented May 2, 2017

Hello @njafei

Yes, SQLCipher 3.4.1 on macOS will be able to read a SQLCipher database created using SQLCipher for Android 3.5. Note the latest version of SQLCipher for Android is 3.5.7.

@sjlombardo

This comment has been minimized.

Show comment
Hide comment
@sjlombardo

sjlombardo Aug 2, 2017

Member

Closed for lack of updates

Member

sjlombardo commented Aug 2, 2017

Closed for lack of updates

@sjlombardo sjlombardo closed this Aug 2, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment