R
rbfigueira
Hi friends,
In our institution we want to install the Membership Database (tables,
stored procedures, views, etc) in one separated database for share of all web
application (avoid installing in each new asp.net application database all
the tables, stored procedures, views, etc for support the Membership). The
problem is if some web application (developer) put the same applicationName
in the web.config file and destroyed or changes the data from other web
application.
I think you are the two guys that can answer to this Security Problem -
Membership.
Normally, an instance of SqlMembershipProvider knows which application name
to use by looking at the value of the applicationName configuration
attribute. The default configuration in machine.config sets applicationName
to /, so most developers will probably want to explicitly redefine membership
providers in their applications to use a more suitable name.
The one constraint on the applicationName attribute though is that it is
statically defined. After you set the value in configuration, the provider
remembers that value for the rest of its lifetime.
Suppose this approach:
In one server you have 3 Databases.
1- Membership Database (tables, stored procedures, views, etc) for
supporting the membership providers. The idea here is to share the same
structure (database) and avoid installing in each new asp.net application
database all the tables, stored procedures, views, etc for support the
Membership.
2- Database "site1" that support one application asp.net 2.0 -
applicationName ="site1"
3- Database "site2" that support one application asp.net 2.0 -
applicationName ="site2"
We have 2 distinct asp.net 2.0 applications. One has in the web.config the
applicationName ="site1" (refers to the Database (2) "site1" and use the
Membership Database (1)) and the other has the applicationName ="site2"
(refers to the Database (3) "site2" and use the Membership Database (1)). In
both applications we can create the users and assign different permissions.
Security Problem:
In the Membership Database (1) we have different roles, profiles, etc for
each different web application. If someone/programmer install other different
asp.net application in the same server (example: "site3") and use the same
Membership ConnectionString and give, for mistake, the same applicationName
(ex: applicationName ="site2") of other asp.net web application that allready
exist, this "new" application will override or can change the Membership data
(roles and users profiles) of the "site2" ?
Note that the Membership Database will be the same to all asp.net web
applications and we will give to the programmer the same Membership
ConnectionString (credentials).
This problem is real ? If yes, what we can do to avoid that problem?
Best regards
In our institution we want to install the Membership Database (tables,
stored procedures, views, etc) in one separated database for share of all web
application (avoid installing in each new asp.net application database all
the tables, stored procedures, views, etc for support the Membership). The
problem is if some web application (developer) put the same applicationName
in the web.config file and destroyed or changes the data from other web
application.
I think you are the two guys that can answer to this Security Problem -
Membership.
Normally, an instance of SqlMembershipProvider knows which application name
to use by looking at the value of the applicationName configuration
attribute. The default configuration in machine.config sets applicationName
to /, so most developers will probably want to explicitly redefine membership
providers in their applications to use a more suitable name.
The one constraint on the applicationName attribute though is that it is
statically defined. After you set the value in configuration, the provider
remembers that value for the rest of its lifetime.
Suppose this approach:
In one server you have 3 Databases.
1- Membership Database (tables, stored procedures, views, etc) for
supporting the membership providers. The idea here is to share the same
structure (database) and avoid installing in each new asp.net application
database all the tables, stored procedures, views, etc for support the
Membership.
2- Database "site1" that support one application asp.net 2.0 -
applicationName ="site1"
3- Database "site2" that support one application asp.net 2.0 -
applicationName ="site2"
We have 2 distinct asp.net 2.0 applications. One has in the web.config the
applicationName ="site1" (refers to the Database (2) "site1" and use the
Membership Database (1)) and the other has the applicationName ="site2"
(refers to the Database (3) "site2" and use the Membership Database (1)). In
both applications we can create the users and assign different permissions.
Security Problem:
In the Membership Database (1) we have different roles, profiles, etc for
each different web application. If someone/programmer install other different
asp.net application in the same server (example: "site3") and use the same
Membership ConnectionString and give, for mistake, the same applicationName
(ex: applicationName ="site2") of other asp.net web application that allready
exist, this "new" application will override or can change the Membership data
(roles and users profiles) of the "site2" ?
Note that the Membership Database will be the same to all asp.net web
applications and we will give to the programmer the same Membership
ConnectionString (credentials).
This problem is real ? If yes, what we can do to avoid that problem?
Best regards