Results 1 to 5 of 5

Thread: What is the Best Method for 2 way data transfer?

  1. #1
    daveaton is offline VB.NET Forum Newbie
    .NET Framework
    .NET 4.0
    Join Date
    Oct 2011
    Posts
    3
    Reputation
    0

    Question What is the Best Method for 2 way data transfer?

    I am looking for the best method of sharing database info between an vb.net desktop app and a server?


    I am wanting to start a membership website where people can signup from my PHP/Mysql server and clients download an VB.net App.

    When the VB.net app is loaded it asks for a username and password that was signup up earlier.

    I have about 150 records that the user can modify on the membership.

    Here is what I thought about doing. but I am not sure if there is a better way.



    After the user successfully logs in to the software, download all records in maybe a CSV file then take that file and create a on the fly database using SQLite so all records can be used by the software. For every record that was modified create another CSV file and reupload to server where the server would change the MYSQL database for that client.

    Here are my limits that I don't want.

    1. The software must not ever connect directly with the mysql server, no passwords of any kind must be in the software.

    Problems that I can see.
    1. If the user does not click a button to reupload the CSV file then no changes would be made to the server.


    What would be the best way to handle this?

    Thanks.

  2. #2
    Herman is offline VB.NET Forum Idol
    .NET Framework
    .NET 4.0
    Join Date
    Oct 2011
    Location
    Montreal, QC, CA
    Posts
    865
    Reputation
    1211
    If you need an easy way to carry data between client and server securely, I would look into opening an encrypted SSH channel between the two. SSH is extremely easy to setup server-side, and client side there are libraries like sharpSSH you can use. Keep in mind just because it's called a secure "shell" doesn't mean you actually need an actual shell on the other ends. You can use SSH to encapsulate any other protocol. Server end could be a simple protected command interpreter that has its own SQL connection to the database.

  3. #3
    JohnH's Avatar
    JohnH is offline VB.NET Forum Moderator
    .NET Framework
    .NET 4.5
    Join Date
    Dec 2005
    Location
    Norway
    Posts
    15,080
    Reputation
    2802
    Quote Originally Posted by daveaton
    I am looking for the best method of sharing database info between an vb.net desktop app and a server?
    1. The software must not ever connect directly with the mysql server, no passwords of any kind must be in the software.
    What would be the best way to handle this?
    It is very common to implement a (wcf) web service and use that as middleware.
    Quote Originally Posted by Herman
    I would look into opening an encrypted SSH channel
    SSH is a Unix protocol, the Windows "counterpart" is SSL and is widely supported by .Net Framework.

  4. #4
    Herman is offline VB.NET Forum Idol
    .NET Framework
    .NET 4.0
    Join Date
    Oct 2011
    Location
    Montreal, QC, CA
    Posts
    865
    Reputation
    1211
    Secure SHell and Secure Socket Layer are two completely different beasts. SSH is no more UNIX than any other protocol, and UNIX also supports SSL.

    SSH is a lot simpler to use, as there is only need for a one-time interactive login, and no complicated certificate management scheme to learn. SSL is also outdated, TLS is the new SSL.
    Last edited by Herman; 11-06-2011 at 2:11 PM.

  5. #5
    JohnH's Avatar
    JohnH is offline VB.NET Forum Moderator
    .NET Framework
    .NET 4.5
    Join Date
    Dec 2005
    Location
    Norway
    Posts
    15,080
    Reputation
    2802
    I see what you mean, though they are both transport layer protocols, and when you look at appliance they usually divide by OS like that. The SSL/TLS integration in .Net should also not be taken lightly.

    SSL/TLS is often used interchangably (esp. SSL), for example the FtpWebRequest class has a EnableSsl property that issues a "AUTH TLS". In SslProtocols Enumeration you can find members such as Ssl2, Ssl3 and Tls. Protocol wise they are successors, to the point that TLS 1 equals SSL 3.1 and even implements downgrading to SSL version 3.

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •