Hi mdbbound,
there are more real examples also how you can set it and how you can prevent unauthorized user.
Following is the link of real example.
http://www.cargilldci.com/
Regards,
---Pinal
Main Topics
Browse All TopicsHello,
Please a little clarification.
I have been reading about setting security on my application and came across with this
set the value for #cgi.script_name#. I just don't get it.
OK if after all the checking and validation and authenticating is done, i want the user the be presented with the "startuppage.cfm"
The full code in the book is:
<cflocation url="#cgi.script_name#">
Thanks.
This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.
Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.
If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.
Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.
Access the answers to your technology questions today.
30-day free trial. Register in 60 seconds.
Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Try it out and discover for yourself.
30-day free trial. Register in 60 seconds.
Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.
Hi mdbbound,
there are more real examples also how you can set it and how you can prevent unauthorized user.
Following is the link of real example.
http://www.cargilldci.com/
Regards,
---Pinal
You cann ot set the value for cgi.script_name
This variable is automatically set by the server.
You can access the value - as the example code shows (as in it redirects using a cflocation to cgi.script_name) but you shouldn't be setting it.
What security purpose do you think you might get by setting it ?
Hi mrichmon,
good to hear from both of you.
No i just don't understand how the user can go to the specified page say
"startuppage.cfm"
after the username and password has been validated and authenticated.
The WACK (BenForta book) included the cgi code that i mentioned earlier but i just don't know how that can connect to my "startuppage.cfm".
Thanks.
Hi
I am only using the developer version. So does this mean i cannot work on the security right now because I need some settings done in the actual server.
Please help, now I am confused. And lost. In panic.
I will have a presentation and i want to show the login modules. Please.
I want to secure all the pages of my application and restrict the Administrator pages only to Administrators.
I still have some little things to work on my search forms, so If i set the password now, I have to login every time i want to see the effect of the changes.
Thanks
Hi Mrich,
Yes that is the book, and it is in chapter 18.
More specifically,
pages 474-475, Listing 18.3, LoginCheck.cfm - Granting Access When the User Name and Password Are Correct.
Sorry, this is just the way i use any code. I make sure that i understand every part of it and all the required cfm. pages that are mentioned in it. The last line is what confused me.
Thanks for looking into my post, no matter how crazy it is.
Ah well the reason that they use CGII.SCRIPT_NAME is that they are including the template from the application.cfm file which gets run when the page is called.
So if I try to go to "MyOrders.cfm" and that page requires a login then the application.cfm includes the login page and does <cflocation url="#CGI.SCRIPT_NAME#"> as the page to go to upon success. When the page runs the server fills in the page I was trying to go to into the CGI.SCRIPT_NAME i.e. MyOrders.cfm and I am taken to that page if my login succeeds.
But if I want the user to always go to "startuppage.cfm" when they successfully log in then I would not use CGI.SCRIPT_NAME, but would actually put the startuppage.cfm into the cflocation since I do not want the user going where they were trying to go, but to instead go to my startup page.
Business Accounts
Answer for Membership
by: pinaldavePosted on 2004-08-12 at 10:53:40ID: 11786378
Hi mdbbound, ums/viewme ssages.cfm ?Forum=11& Topic=268
that is sure for security purpose.
I want to write more... but there is one link which explains everything with example so If I write more itwill be like I am reapting that site.
Please visit
http://www.easycfm.com/for
Regards,
---Pinal