Forms Authentication adding new users programatically

Ask a Question related to ASP.NET Security, Design and Development.

  1. #1

    Default Forms Authentication adding new users programatically

    How do you add new users programatically using Forms Authentication in
    ASP.Net? There must be a way to do this besides editing the
    web.config file by hand or attempting to modify the web.config file
    using an XmlDataDocument.

    This is a requirement I have to meet for a project Admin users must be
    able to add new users. And since I'm using Forms Authentication to
    bind the current user with roles stored in SQL server I'd hate to
    abandon it.
    Scott Roberts Guest

  2. Similar Questions and Discussions

    1. Programatically adding an HTTPHandler
      When my custom control is dropped onto a web page at design time, I want an associated HTTPHandler reference to be automatically added to the...
    2. Programatically adding an Object Tag to a TemplateColumn?
      Hi All, I am trying to add flash movie to a templatecolumn of my datagrid. The flash movie takes variables to play different sample mp3 tunes....
    3. Redirecting anon users - Forms or Windows Authentication
      I have an Intranet site that I'm trying to work out some authentication issues on. Eventually, I want all of our domain users to add the url for the...
    4. Adding <div> tag programatically
      Hi All, I would like to add the <div> tag programatically from the code-behind of my aspx file. Basically, I would like to a table to this <div>....
    5. Forms Authentication - "Deny users = ?" necessary
      Thanks for your reply Hernan. I can't believe Authentication and Authorization are mixed... If I want to identify/authenticate a user (for...
  3. #2

    Default Re: Forms Authentication adding new users programatically

    You are going to need to put your users somewhere else, like SQL Server
    [url]http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnnetsec/html/SecNetHT03.asp[/url]

    You could edit Web.Config theoretically, but realize that the second you do that, your Application will restart, and you'll lose all sessions.

    --Michael


    "Scott Roberts" <sroberts20740@comcast.net> wrote in message news:66646186.0406021238.3d214e6b@posting.google.c om...
    > How do you add new users programatically using Forms Authentication in
    > ASP.Net? There must be a way to do this besides editing the
    > web.config file by hand or attempting to modify the web.config file
    > using an XmlDataDocument.
    >
    > This is a requirement I have to meet for a project Admin users must be
    > able to add new users. And since I'm using Forms Authentication to
    > bind the current user with roles stored in SQL server I'd hate to
    > abandon it.
    Raterus Guest

  4. #3

    Default Re: Forms Authentication adding new users programatically

    You should put your users in a extern datasourc such as SQL servern or AD..
    (If you use SQL-server, modell a data base wich connect users to groups..)
    Then in your app. you could authenticate users against groups instead of
    specific accounts..

    This will result in that you dont need to do any changes in your app.(unless
    you architecture of the app, changes) Instead you manipulate the users group
    membership in your choosen datasource..

    "Scott Roberts" <sroberts20740@comcast.net> skrev i meddelandet
    news:66646186.0406021238.3d214e6b@posting.google.c om...
    > How do you add new users programatically using Forms Authentication in
    > ASP.Net? There must be a way to do this besides editing the
    > web.config file by hand or attempting to modify the web.config file
    > using an XmlDataDocument.
    >
    > This is a requirement I have to meet for a project Admin users must be
    > able to add new users. And since I'm using Forms Authentication to
    > bind the current user with roles stored in SQL server I'd hate to
    > abandon it.

    Robert Wallström Guest

Posting Permissions

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

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139