Re: What's My Password?

Tech-Archive recommends: Fix windows errors by optimizing your registry



I'm a long time programmer who has not done much database programming (I've
worked with Access a bit and did one write a Visual Basic application that
used the Jet database engine many years ago).

I don't know which of the many various technical options I "want". I simply
want to be able to create a database and then access it from my Web
application (written using the full version of Visual Studio 2005) and have
it reasonably secure. If my code needs a user name and password then that's
just fine as long as I have some control over what they are.

At this point, it would be nice just to be able to start writing a little
bit of database code that works even if it requires Integrated Giblet Widget
Security technology.

I'll take a look at the article you referenced. Unfortunately, I'm not
hopeful it will answer my questions at this point.

Thanks.

--
Jonathan Wood
SoftCircuits Programming
http://www.softcircuits.com

"Miha Markic [MVP C#]" <miha at rthand com> wrote in message
news:O10PSNwMHHA.3312@xxxxxxxxxxxxxxxxxxxxxxx
Hi Jonatahan,

Well, it depends on some factors.
1. Do you wanna use integrated security (credentials that process is
running under). More secure and recommened as you don't have to store
password anywhere.
2. Do you want to use sql authentication. Less secure as you have to
provide username and password.
3. If 2 then you have to make sure your sql express is configured to allow
sql authentication.
4. If 1 then you have to give sql server privileges to the account under
which your asp.net application is running.

Here is a good article on the topic
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnnetsec/html/SecNetch05.asp

Also be aware that default asp.net processes on 2003 uses different
credentials than the one on xp.

HTH
--
Miha Markic [MVP C#, INETA Country Leader for Slovenia]
RightHand .NET consulting & development www.rthand.com
Blog: http://cs.rthand.com/blogs/blog_with_righthand/


"Jonathan Wood" <jwood@xxxxxxxxxxxxxxxx> wrote in message
news:OtPeTqtMHHA.1252@xxxxxxxxxxxxxxxxxxxxxxx
Grrr...

I've spent the last several hours trying to learn ADO.NET. Specifically,
the database connection stuff.

I finally managed to create a database and enter some data within the VS
IDE. I have several ADO.NET books but not one could tell me how to set up
my password.

To make a long story short, I ended up setting up a connection using
(local)\SQLEXPRESS since that's what the only example I could find uses
and I have no idea what to enter for regular MS SQL.

But I didn't have a change to enter a password or anything like that.
Based on another book, I tried all of the following:

string connString = "Data Source=localhost;Initial
Catalog=BlackBeltCoder;Integrated Security=True";
string connString = "Data Source=localhost;Initial
Catalog=BlackBeltCoder;Integrated Security=SSPI";
string connString = "Data Source=localhost;Initial
Catalog=BlackBeltCoder;user id=sa;password=opensesame";

SqlConnection conn = new SqlConnection(connString);
conn.Open();

In each case, the code fails on the call to Open(). Here's the message I
get:

"An error has occurred while establishing a connection to the server.
When connecting to SQL Server 2005, this failure may be caused by the
fact that under the default settings SQL Server does not allow remote
connections. (provider: Named Pipes Provider, error: 40 - Could not open
a connection to SQL Server)"

Well, that's very helpful. I'm not using a remote connection.

I'm running my Web site in the IDE and will still need to figure out how
to connect to the database once I copy the site to my Web hosting account
but I can only deal with so much pain at once.

Is there any help available to figure out how to connect to the database
I have connected?

--
Jonathan Wood
SoftCircuits Programming
http://www.softcircuits.com





.



Relevant Pages

  • Re: My Book is Incomplete Regarding SQL Commands ;-(
    ... Hitchhiker's Guide to Visual Studio and SQL Server ... Create a Connection object and pass in a ConnectionString to ... manage the database table you reference. ...
    (microsoft.public.dotnet.framework.adonet)
  • Re: provider: Named Pipes Provider, error: 40 - Could not open a c
    ... I have tried connecting to Sql Management Studio and it worked pretty much ... An error has occurred while establishing a connection to the server. ... under the default settings SQL Server does not allow remote connections. ... I have a sql server install / database on the web server. ...
    (microsoft.public.sqlserver.connect)
  • RE: Logging in in background
    ... wold take all kinds of modifictions as I'd need to be checking that each SQL ... my database and all have connection strings associated with them. ... I suspect that there is also an issue on the SQL Server side as I keep ...
    (microsoft.public.access.modulesdaovba)
  • Re: User not associated with trusted SQL Server connection
    ... > using the osql utility. ... > associated with a trusted SQL Server connection. ... > database or is it just for that instance. ...
    (microsoft.public.sqlserver.security)
  • RE: Manipulating MS Access records with excel VBA + ADO
    ... While I cannot see how a working example of a connection to a database is ... Select the control button view dataor edit query. ... Look for SQL button to get the SQL ...
    (microsoft.public.excel.programming)