I have an directory structure like this:
localhost/site/myapp
localhost/site/myapp/author/
localhost/site/myapp/revisor/
localhost/site/myapp/editor/
localhost/site/myapp/admin/
myapp is an application and is where my web.config is located. I must
create 4 completely separated areas for authors, revisors, and editor
and an admin. The 4 areas will be completely different, so i put each of
them in a different folder.
So, each of the 4 folders have a login form, the user authenticates and
can do his job. I am trying to use the Form Authentication that ASP.NET
provides, but i don`t want an user authenticated for "author" to have
access to "revisor" area... or an "editor" have access to "admin". there
are no privilegies, no admin will access author area. So each folder
will have it`s own authentication.
I tried this:
[localhost/site/myapp/web.config]
<configuratio n>
<location path="author">
<authenticati on mode="Forms">
<forms name="AUTHOR_AU TH" loginUrl="~/author/login.aspx" />
</authentication>
<authorizatio n>
<deny users="?">
</authorization>
</location>
<location path="revisor">
<authenticati on mode="Forms">
<forms name="REVISOR_A UTH" loginUrl="~/revisor/login.aspx" />
</authentication>
<authorizatio n>
<deny users="?">
</authorization>
</location>
<and etc="... =)"/>
</configuration>
but it`s not redirecting to the login page.. i can enter any folder
always. I don`t know if my web.config is wrong, or Windows
Authentication comes first to authorize...
anyone can help?
thanks... 3 2164
you can only have one auth method per site/vd.
You will have to create each with its own virtual dir if you want it to have
it's own auth
Otherwise, have them login at the top level, and control auth based on
groups,id's,etc
--
Curt Christianson
Owner/Lead Developer, DF-Software www.Darkfalz.com
"Natan" <nv***@mandic.c om.br> wrote in message
news:ek******** ******@tk2msftn gp13.phx.gbl... I have an directory structure like this:
localhost/site/myapp localhost/site/myapp/author/ localhost/site/myapp/revisor/ localhost/site/myapp/editor/ localhost/site/myapp/admin/
myapp is an application and is where my web.config is located. I must create 4 completely separated areas for authors, revisors, and editor and an admin. The 4 areas will be completely different, so i put each of them in a different folder.
So, each of the 4 folders have a login form, the user authenticates and can do his job. I am trying to use the Form Authentication that ASP.NET provides, but i don`t want an user authenticated for "author" to have access to "revisor" area... or an "editor" have access to "admin". there are no privilegies, no admin will access author area. So each folder will have it`s own authentication.
I tried this:
[localhost/site/myapp/web.config] <configuratio n> <location path="author"> <authenticati on mode="Forms"> <forms name="AUTHOR_AU TH" loginUrl="~/author/login.aspx" /> </authentication> <authorizatio n> <deny users="?"> </authorization> </location>
<location path="revisor"> <authenticati on mode="Forms"> <forms name="REVISOR_A UTH" loginUrl="~/revisor/login.aspx" /> </authentication> <authorizatio n> <deny users="?"> </authorization> </location>
<and etc="... =)"/> </configuration>
but it`s not redirecting to the login page.. i can enter any folder always. I don`t know if my web.config is wrong, or Windows Authentication comes first to authorize...
anyone can help? thanks...
Curt_C [MVP] wrote: you can only have one auth method per site/vd. You will have to create each with its own virtual dir if you want it to have it's own auth Otherwise, have them login at the top level, and control auth based on groups,id's,etc
what prevents an app from having multiple logins, if you have the
"location" tag to specify different configs for different directories
and the cookie path can be changed?
And how do i disable windows authentication in my app?
web.config wont allow it, it's part of the asp.net framework I believe. ONE
auth type per "site/vd". You can override/exclude/include but you can't set
multiple types
--
Curt Christianson
Owner/Lead Developer, DF-Software www.Darkfalz.com
"Natan" <nv***@mandic.c om.br> wrote in message
news:%2******** ********@TK2MSF TNGP10.phx.gbl. .. Curt_C [MVP] wrote: you can only have one auth method per site/vd. You will have to create each with its own virtual dir if you want it to
have it's own auth Otherwise, have them login at the top level, and control auth based on groups,id's,etc
what prevents an app from having multiple logins, if you have the "location" tag to specify different configs for different directories and the cookie path can be changed?
And how do i disable windows authentication in my app? This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Suresh Gladstone |
last post by:
Hi,
This is a bit with versioning and installation of
the .NET dlls. I want to perform the following,
1. A third party application will be invoking my .NET dll
through COM interop . For this I have used Regasm and
registered the assembly in the registry with CODEBASE
option.
eg: regasm myDll.dll
/tlb:myDll.tlb /codebase
|
by: Simon Harvey |
last post by:
Hi chaps,
Can someone tell me the following:
If I declare a site wide config file and then want to overide it in a secure
directory, do I need to have a complete config file, or can I just overide
the settings that I want to change from the default.
If I need to have a complete config file, where can I find out the absolute
minimum that I need to put into it. The web.config file that Visual Studio
|
by: BPearson |
last post by:
Hello
I would like to have several sites share a single web.config file. To accomplish this, I would point the root of these sites to the same folder. Is there any reason why I might not want to do this? (IIS 5 or 6
In case you're wondering why I would do this, we have many web sites on a single server, and there are groups of sites that need to share common configuration information. I'd like to ease some administration by having one...
|
by: Bennett Haselton |
last post by:
If I add this to my web.config file:
<authentication mode="Forms">
<forms name=".ASPXUSERDEMO" loginUrl="login.aspx" protection="All"
timeout="60" />
</authentication>
I can configure the application so that users who try to access a page
in the application, get redirected to login.aspx where they have to
sign in. (And the "signing in" is handled in the codebehind page of
|
by: Benny Ng |
last post by:
Hi,all,
How to let the sub-directory to avoid the authentication control from Root's
webconfig?
I heard that we can add a new web.config to the sub-directory. And then we
can slove the problem.
Virtual directory is £ºhttp://localhost/main
Sub-directory is : http://localhost/main/reminder
| |
by: Eric Sabine |
last post by:
This situation requres many exes to be sitting on a network share. I would
like all of these to use the same app.config file, which will be stored in
the same location on the network. A quick test though gave me this
exception:
System.InvalidOperationException: The key 'ConnectionString' does not exist
in the appSettings configuration section.
at System.Configuration.AppSettingsReader.GetValue(String key, Type type)
at...
|
by: Khodr |
last post by:
Hello,
I am using VS.NET 2003 and vb. I build my application MyApp and it generates
MyApp.exe.config. So now MyApp.exe reads parameters from MyApp.exe.config.
Great and no problem!
I need to run the same program but with different configuration data. So I
made a copy of MyApp.exe and MyApp.exe.config to put them in another folder
and renamed the copy to MyApp2.exe and MyApp2.exe.config respectively. I ran
it but it did not read from...
|
by: Andrew |
last post by:
Hi,
I have a default.aspx which allows the user to choose between module Admin
and module B. When the user clicks either one, he will be redirected to a
FormsAuthentication login page. The problem I have is that currently, users
of one module are able to access the other since I have only 1 login page.
How do I prevent this ?
I am not sure how to go about configuring the web.config file for having 2
modules that have a separate set of...
|
by: mmcd79 |
last post by:
I built a VB.net application that makes use of a machine level DB
connection string setting, and a user level starting location setting.
The machine level setting and the default user based setting is of
course stored in the app.exe.config file located in the same directory
as the exe. Upon closing the form, I save the user setting which then
creates a user.config file in the appdata directory in my profile.
This is all well and good....
|
by: Andrus |
last post by:
..NET 2 Winforms application.
How to create new setting and set it default value in userSettings section
of app.config file or overwrite existing setting value ?
I found code below in this list which modifies Application setting section
but how to add new item to userSettings ?
Andrus.
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
| |
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
| |
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
|
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...
| |