locked
How to protect data RRS feed

  • Question

  • User377900 posted

    Hi I want to download xml data from api service and then store it to sqlite, about 1 to 2 MB, I want to prevent users from getting data For data request data , I using ssl and i've added a key parameter to url

    https://api.example.com/default.aspx?key=abcd1234&query=value

    ~~~ If strKey.ToLower <> "abcd1234" Then Exit Sub End If ~~~

    Is this method secure to request data. How to prevent users from getting data ?

    Thank you

    Friday, December 25, 2020 6:01 AM

Answers

  • User382871 posted

    I want to download xml data from api service and then store it to sqlite ... How about encrypting xml data from my api service then stored it in sqlite , would this be a better option?

    Accoding the above info, it needs to store the data to sqlite. So I suggest to use an encrypted database. If you want to encrypt the api service, check this doc.


    Xamarin forums are migrating to a new home on Microsoft Q&A! We invite you to post new questions in the Xamarin forums’ new home on Microsoft Q&A! For more information, please refer to this sticky post.

    • Marked as answer by Anonymous Thursday, June 3, 2021 12:00 AM
    Wednesday, December 30, 2020 12:28 PM

All replies

  • User382871 posted

    I want to prevent users from getting data To prevent accessing the data, you could add authentication to the api. The user needs to authenticate the identity before obtaining the data.

    Here are the related tutorials you could refer to: https://docs.microsoft.com/en-us/xamarin/essentials/web-authenticator?tabs=android https://docs.microsoft.com/en-us/xamarin/xamarin-forms/data-cloud/authentication/rest


    Xamarin forums are migrating to a new home on Microsoft Q&A! We invite you to post new questions in the Xamarin forums’ new home on Microsoft Q&A! For more information, please refer to this sticky post.

    Friday, December 25, 2020 7:59 AM
  • User377900 posted

    Thanks for reply. I meant I had an app that gets data from the api I've developed, the data is big, so it's best to store it in the phone. I might store it in SQLite But I don't want hackers to be able to get data using special tools, and look for solutions to add a layer of security. The app doesn't require signing in.

    Friday, December 25, 2020 4:49 PM
  • User382871 posted

    But I don't want hackers to be able to get data using special tools, and look for solutions to add a layer of security. For this, you could use an encrypted database. The sqlite-net-sqlcipher nuget supports the encrypted function.

    Check the link: https://github.com/praeclarum/sqlite-net#using-sqlcipher


    Xamarin forums are migrating to a new home on Microsoft Q&A! We invite you to post new questions in the Xamarin forums’ new home on Microsoft Q&A! For more information, please refer to this sticky post.

    Monday, December 28, 2020 8:44 AM
  • User377900 posted

    Thanks @Yelinzh How about encrypting xml data from my api service then stored it in sqlite , would this be a better option? and what libraries can I use?.

    Wednesday, December 30, 2020 3:17 AM
  • User382871 posted

    I want to download xml data from api service and then store it to sqlite ... How about encrypting xml data from my api service then stored it in sqlite , would this be a better option?

    Accoding the above info, it needs to store the data to sqlite. So I suggest to use an encrypted database. If you want to encrypt the api service, check this doc.


    Xamarin forums are migrating to a new home on Microsoft Q&A! We invite you to post new questions in the Xamarin forums’ new home on Microsoft Q&A! For more information, please refer to this sticky post.

    • Marked as answer by Anonymous Thursday, June 3, 2021 12:00 AM
    Wednesday, December 30, 2020 12:28 PM