Blog Entry: 3/25/2006 4:47:07 PM
Where is the system getting the random user name and password, and why does it keep selecting the same user name and password every time?
, Hi,
I have a question re ASP Protect, I have got it up and running on a dev server which also hosts a e-com engine (ASP / Access), when users check out they are presented with the e-com log in screen (which is sharing the same ASPP_User table). All's well and registration and editing user details is fine both in the Admin section and the front end of ASP and if I request an email reminder from the ecom scripts I get back the encrypted password.
I'm using <% = Session("Email") %> and <% = Session("Password") %> to populate the fields on the ecom log in page so users can click though and progress, the checkout process needs the username/password, all user info shows up ok, however, when I proceed with these credentials, it doesn't work, even though I know these to be correct and even without requesting a password reminder and using the one that gets me in everywhere else, I still can't get through? do I need some code re the crypto so the ecom can decode??
Any help would be great - I've been on it for about 10 hours, and checked through the posts here but can't fathom it out?
Thanks Craig
,
Ahhh....yes, I always forget about the cache. That's exactly what it was.
I had made modifications to the import_pics.asp file, because I added more fields to the db, and made the import folder path dynamic, but I seem to have forgotten to add in the response.expires=0
Once I added this back in it has stopped messing up.
What was happening was, it wasn't overwriting the files, nor were they too big, but you would click on one thumbnail in an album(category) and it would display a picture from a totally different category. It seems browser cache was the culprit, however.
Thanks for the quick reply, great product tooo!!!
, How to set a new users expiration date.
You'll need to edit the "users/add_new_account.asp" with a text editor.
Find this section..
<%
CmdAddUser.Fields("ValidateEmailCode") = ValidateEmailCode
CmdAddUser.Fields("Access_Level") = "4"
' PUT YOUR CODE HERE
CmdAdduser.Update
ID = CmdAdduser("ID")
CmdAdduser.Close
Set CmdAdduser = Nothing
ConnPasswords.Close
Set ConnPasswords = Nothing
%>
You'll want to add code like this right between the Acccess_Level and Updates section
CmdAddUser.Fields("Expiration_Date") = Date + 60
That will give take todays date and add 60 days to it.
You can of course do whatever you want here.
Actually, any database value for the user can be set during registration.
You can also change the default Access_Level to whatever you like.
cwilliams38088.4986689815, I have an asp page that includes other asp pages via an include. for example:
snippet code: file name: collaboration.asp
<table bgcolor="#bed1e4" border="0" cellspacing="0" cellpadding="10" marginwidth="0" marginheight="0" leftmargin="0" topmargin="0">
<tr>
<td>
<!--#include file="../../../filetransfer/directory_listing2.asp" -->
<BR><BR>
<!--#include file="../../../filetransfer/upload.asp" -->
</td></tr>
</table>
I can add the code below to collaboration.asp and it seems to work,but I cant seem to figure out how to protect the other files such as upload.asp at the same time. -- can you help? - Note: as soon as I add the code below (and adjust the path) - I cant bring up the page.
This is the protection code I am using.
<!--#INCLUDE FILE="../../../../aspprotect/check_user_inc.asp"-->
Shirely
, that wont work the way you did it because groups are not stored like like.
groups are stored "*1*"
or "*1*,*9,*"
so if you test for them you must do so using the InStr function of vbscript
example:
If InStr(Session("Groups"),"*1*") Then
' do whatever
End If
also.. as for the session variable
it should be Session("Groups")
And in Version 6.... (its all ready to go in version 7) that session variable must be saved in the check_user_inc.asp file near where all the others are saved. If it is not there by default "I dont remember if it is or not" you have to add it like so near where all the others are saved
Session("Groups") = CmdCheckUser("Groups")
If you are wondering if it is being saved correctly you can always response.write out the Session("Groups") to see if it holds a value
, humm, yea thats a data connection error..
really not related to the asp code in the application for the most part.
that is low level
If using MSACCESS
I would make sure permissions are set correctly on the database folder (not just the database file itself)
I would make sure your using at least a 2000 version of the database. 2003-2003 format being better..
I would make sure the server has up to date mdac/odbc drivers.. (that is really the server admins responsibility)
As for permissions there are articles in our forums about exactly how they need to be set. Improper permissions can cause a ton of random errors like that.
cwilliams38414.6528240741, yes, How can I have fixed size height and width image without distortion. Is there a component that I can use or how can I change the existing code.
yes, unless its ratio matches
how could it not be ?
Please keep questions like this in the forums... thx.
there is no need for this to be a private message
-- Previous Private Message --
Sent by : eeye
Sent : April/29/2005 at 2:19pm
If I choose fixed width and height is the thumbnail image going to be distorted?
-- Previous Private Message --
Sent by : cwilliams
Sent : April/29/2005 at 1:17pm
that is not possible unless you rewrite the code.
You onlyahve the two options we give in the config file for thumbnails
fixed width and height all the time
or
fixed width / dynamic height
-- Previous Private Message --
Sent by : eeye
Sent : April/29/2005 at 1:07pm
Hi William
One more questions for you. is there a way to make sure that all the thumbnails are the same size without distorting the images (in the thumbnails). Or if a picture's height is bigger than its width is there to create the thumbnail such that the height of the orginal becomes the width of the thumbnails and vice versa.
Basically I just want the thumbnail pictures to be in a perfect row with all the picture heights the same and all the pic width the same.
Thanks
Sean
, It a generic error that means something is wrong with your data connection.
http://support.cjwsoft.com/code/moreinfo27-1.htm
http://support.cjwsoft.com/code/moreinfo136-1.htm
, expiration dates are not used in aspprotect's database when signing someone up using PayPal subscriptions because the PayPal system keeps track of all of that and will automatically send posts to the approtect system if a user needs to be deactivated for not paying or for whatever reason.
As you will notice in that thread about subscriptions the paypal signup data you use for the person determines their membership pricing and details..
http://support.cjwsoft.com/forum/forum_posts.asp?TID=186& ;PN=1
Basically the system takes care of everything.
PayPal takes care of everything.
However you want to look at it.
cwilliams38446.6609953704, If you have found out that parent paths are disabled on the web server you can still use the application.
Before you continue.
If it is your server consider enabling parent paths to solve the problem.
If it is not your server consider asking them to enable parent paths for your web site to solve the problem.
If that is not possible please download this zip file.
2005-02-20_150703_aspprotect_v7.x_alternate_include_file_pat hs.zip
This zip file contains 3 sets of alternate files depending on your situation. You simply replace your existing aspprotect v7.x files with these new ones.
The zip file contains the following folders and files.

Below is the contents of the readme.txt file which explains everything.
The following folders each have a version of all the files in the ASPProtect system that might need to be edited in case you need to change the paths for the server side include files. There are 3 different scenarios.
(parent paths enabled) - This is the way the application comes.
The files in this folder have FILE server side includes containing "../" information. While these includes will work when the applicaion in is any location of a website they will not work if parent paths are disabled on the web server. Generally you will want to use these on your xp development machine. You can of course use them on your real server if parent paths are enabled. Parent Paths are now disabled on II6 by default and some hosting company will not enable them.
(domain root)
The files in this folder have VIRTUAL server side includes in them.
These includes only work when the applicaion is installed in the root of your web domain. For example if your domain was called "www.somedomain.com" the following aspprotect files and folders would end up like this
"http://www.somedomain.com/check_user_inc.asp"
"http://www.somedomain.com/password_admin"
"http://www.somedomain.com/users"
(domain directory)
The files in this folder have VIRTUAL server side includes in them.
These includes only work when the applicaion is installed in a directory called "aspprotect" in the root of your web domain. For example if your domain was called "www.somedomain.com" the
following aspprotect files and folders would end up like this
"http://www.somedomain.com/aspprotect/check_user_inc.asp"
"http://www.somedomain.com/aspprotect/password_admin"
"http://www.somedomain.com/aspprotect/users"
You can change the name of the "aspprotect" directory but you will will have to edit the includes in the files.
Lastly, if you are on a local machine and insist on using the VIRTUAL INCLUDES you would also use the (domain directory files) even though you dont have a domain on your local machine most likely
For example if your site was installed like so.
"http://localhost/aspprotect/check_user_inc.asp"
"http://localhost/aspprotect/password_admin"
"http://localhost/aspprotect/users"
cwilliams38403.6836342593, One of my users is looking to do mass updates (multiple records). He wants to be able to update the "Expiration Date" for a group of users who work for the same company. , Aggh.. I put passwords instead of password. Sorry to have bothered you, works fine now. , [QUOTE=cwilliams]actually, passwords can be up to 75 characters long in ASPProtect.
the only requirement when entered from a non admin user is that they are at least 4 characters long.
what does MSAccess have to do with this ? Are you trying to convert and old system or something? I noticed you created and "old password" field in there ? Is there something I do not know about as far as what you are trying to do?
Passwords in version 7 are encrypted so I hope you understand all of that and realize you can not enter or change passwords right from SQL server. Also if you import info you must handle that accordingly and convert the passwords to encrypted format. [/QUOTE]
First off, I haven't imported anything from MS Access.. The only reason I mentioned it is cuz I thought initially it worked with Access and not SQL server.
I am not converting nor entering any data manually into the db, nor have I changed anything in the way the registration is made (don't know where the "Old password" has come from? thought it was a function you made?)
, I have reviewed the permissions requirements for folders from the support documentation but do not see the 'internal guest' account shown in our system to allow internet access to read/write to the access database.
How else can we locate the proper account (or is it possible there is none?) to use to allow permissions to access the Data directory if it doesn't show up as 'Internal Guest'?
cwilliams38417.7773032407, Can I have the logon be in a top frame while having the protected pages displayed in a main frame?
Using frames with forms based authentication is not the best thing to be doing. Your much better off not using frames and using includes files to do a virtual frames sort of thing (search google) but if you are going to use frames I would suggest password protecting the frameset page as well as any pages it contains.
If you want to have a login form in a non protected top frame all the time.. that posts to a lower frame that is password protected.. you would do this
http://support.cjwsoft.com/code/moreinfo169-1.htm
but change the target of the form to one of your frames
personally though I think that would be a somewhat goofy setup to have going on
Also, how will it behave if a user moves in between a protected page to a public page and back to the protected page again?
As long as they have cookies enabled which is required for session variables to work... then you will have no issues because once they come back to a page they have permission to they will just be allowed in without login.. at least while that session is still active.. or for a longer time if they choose the remeber me option which keeps track of them with a cookie .
Really, the best thing to do is expirment and see how things behave.
, I don't believe that the iframe method is supported in a .NET (aspx) implementation, is it?
JDooley
, ASPProtect v7.x has a new feature called groups.
Groups are meant as a replacement for using the access levels as they are much more powerful. Support for pages protected using access levels is left in tact for backward compatiability for a customer that was using them.
A customer recently told me groups could not be used like access levels and that 8 access levels was not enough. This is how I explained that groups can do everything access levels can do.
Groups can honestly do everything access levels can do if you really think about it.
Using groups and protecting pages accordingly you could actually create a system that basically worked identically to the way the access levels works.
For example..
You make 8 groups and assign users to them accordingly
Protection code on page allows access to groups 1-8
The aspprotect system generates this code for you…
<% GROUPACCESS = "1,2,3,4,5,6,7,8" %>
<!--#INCLUDE FILE="check_user_inc.asp"-->
In this case a user assigned to any one of those groups would have access..
Protection code on page allows access to groups 2-8
The aspprotect system generates this code for you…
<% GROUPACCESS = "2,3,4,5,6,7,8" %>
<!--#INCLUDE FILE="check_user_inc.asp"-->
In this case a user assigned to any group between 2-8 would have access..
Protection code on page allows access to groups 3-8
The aspprotect system generates this code for you…
<% GROUPACCESS = "3,4,5,6,7,8" %>
<!--#INCLUDE FILE="check_user_inc.asp"-->
In this case a user assigned to any group between 3-8 would have access..
and so on... I think you should get the picture by now
, When I enter www.vickerylightning.com/aspgallery/dataconn_inc.asp on the screen it says "Not a valid bookmark"
as far as that goes I have no idea.. I have never seen that message before but you are not suppose to run that page by itself regardless.. it is an include file not meant to run on its own
, Windows 2000 server you said ? Just checking on that one ?, Hope the wedding went well. I have one this weekend.
I was successful at performing an upload. The free upload software was either not configure properly (probably) or not working. I downloaded the trial version of softartisan's upload (which is like over $300) and it started working.
Can more than one photo be uploaded at one time (like a whole folder full of photos) or does each have to be done individually?
, I just got home from a lonnng trip.. I will try to answer this 1st thing in the morning.
CJW, It turns out that I never enabled ASP.net on the site. After doing that the skins work much better. I'll have to poke around and see what other functionality is now available.
Thanks!
Al
, Thanks
It wasn't a complaint. I just bought it last night and installed it today. But, I must have missed the part about requiring Enterprise Manager for installing it on SQL.
If you want it the link to the Web Based SQL Manager is : http://www.aspenterprisemanager.com/ which is free and the Trialware that I tried is EMS SQL Manager.
Maybe that will help a little in not requiring that people have an MS SQL license to access their hosted MS SQL to install the software.
Thanks
, Help!.. I need to export the username and password fields to a mail merged letter so everyone knows their username and passwords. However whenever i access the database or do an export. The passwords showup as encrypted. Is there a way to access the list, un encrypted?
thanks
, Hi,
I can't seem to find the code where it limits the upload file size. I want to limit the upload size to 1.5 mg for all users. Also I've noticed that the 500 pix doesn't seem to work. As in if an image is bigger than 500 pix the script still uploads it. i am using Upload_post_VBSCRIPT.ASP.
Thanks
, I dont get it.. I am still looking into it..
I think this has something to do with your original experience when things would work and then not work.
something weird is going on
, ok thanks, I do not really know a lot about but it is basically code that lets you specify however many number of images and links... and then display a certain number of them at once.
You'd have to search google for it.. there are 1000 of sites that offer free javascript code and that is where you find scripts like that.
You could certainly set up all the images and links for each banner in aspbanner but if you used them with code like that you be limited to tracking clicks on banners. Tracking page impressions would not be possible because the javascript would be handling what images get displayed at any given time. Basically each link for each image would be going through aspbanners tracking url feeding it the banner id and therefore tracking the click and sending the user to the desirec URL.
Regardless, it is not something I would support. You would have to sort it out as it is nothing ASPBanner was designed to do and not something I want to deal with because client side javascript code is not something I am NOT very good with. , I am running Windows 2000 server. I do believe asp.net IS installed as I have the .NET 1.1 framework installed.
Funny about the bounce backs. I am at about 10% of my limit, which I control as I am the network admin. I'll check into that.
, I am having severe trouble with the SQL database connection for ASPlisting (generic version).
I have used all of the suggested connection strings but still get error messages such as:
[DBNETLIB][ConnectionOpen (Connect()).]Specified SQL server not found.
I have set up the tables in the database, although the database existed already with many other tables in it as it costs me per database per month so one has to suffice with many tables in it.
I use SQL a fair amount on my site but have not suffered any probs like this yet.
Any advise or help would be useful.
, Kurt,
There really is no default width in general.
The thing to remember is that the default.asp page includes a lot of different pages.. and some of those pages also include pages.
Now all of this gets wrapped by the header and footer include files so in a sense what you do there can effect everything inside to a certain degree.
Now there are some widths set here and there for different tables and what not on certain pages, but its really the kind of situation where you just have to dig around in the code and experiment until you eventualy find what you are looking for and get the desired result.
I'd love to tell you there is easy way to just set a width, but it is not that simple.
Maybe someday it will be. Just not in the current version.
CJW
, Excellent.
Payment now taken in £.
Pasted <input type="hidden" name="currency_code" value="GDP"> into
paypal_signup/paypal2.asp
Thanks Folks.
, Is the user ID case sensetive? In my case I use the user email as the login ID., ok, so from your PM Iknow you are using SQL server with IIS5.
You say you created the SQL database using the provided scripts and that is good.
What is going on may just be a weird odbc issue that sometimes happens on IIS5 when using SQL server and I have an idea on how to remedy it.
Edit the "config_inc.asp" with notepad.
Change
If Application("SERVER_SOFTWARE") = "" Then
Application("SERVER_SOFTWARE") = Request.ServerVariables("SERVER_SOFTWARE")
End If
To
Application("SERVER_SOFTWARE") = "iis/6"
And lets see if that helps the situation.
it will change some SQL String query values in the application from "-1" to "1"
either should always work but under certain scenariois only one or the other works, My client has a list of 13,000 members that
have already been assigned ID's and passwords with a
homegrown system.
When doing a bulk import, will we be able to retain the userid and password or will a new id be assigned during the bulk load?
Thanks in advance for your help.
, Are you aware ASP can run on any machine running win95/95,2000,xp pro, 2003. You really should test all asp code locally before running it on live servers but anyway... that is your deal
I am not sure if memory alone will be enough for that server but it could help. I saw a decent amount of free memory when I looked. Its just about an 8-10 year old system on every aspect (processer,OS,Hard drives, memory etc etc) and not only that something is tasking the heck out of the resources left over for asp database access. Something is just wrong. I don't know what it is but I am pretty sure it is not aspprotect. I got rid of my last nt 4 server about 4-5 years ago but the application always ran great on NT and I still have some customers using NT 4. Not many though.
if you email me the import file and the encryption keys you are using I will make a database for you.. just zip it up and send it to chris-cjwsoft.com
replace - with @ , Hello,
My guess your having trouble setting up a system dsn because the database has a password set on it. Your hosting company most likely sets up DSNs without using the advanced tab which is where the authentication information goes. Or they have some sort of web interface for the customers to use that doesn’t allow setting up that information.System DSN’s are actually difficult to set up correctly when the database has a password on it. There is of course a password on the database for security reasons so if someone ever downloads it somehow they will not get your information.
System DSN’s are not the way to go regardless as you will see mentioned at our support site.
http://support.cjwsoft.com/forum/forum_posts.asp?TID=9&P N=1
You really should try setting up a DSN-less connection. It is the best way to go. They are easier to set up, perform better, and are less load on the server. Any host that wants it customers to use system dsn’s is not on the ball as far as server performance and server resource conservation goes. They are really asking for trouble down the road.
All you need to do to make dsn-less connection is the following.
Get permissions set for the folder the database is in (by your host)… then figure out the physical path on the server to the database by using server.mappath or you simply ask your host for the info.
An article I wrote on using server.mappath
http://www.powerasp.com/content/hintstips/physical-path.asp
Then your connection string will look something like this.. (of course you edit the path to match what server.mappath tells you. And you make sure the database name is correct)
ListingsConnectionString = "DBQ=C:\Inetpub\wwwroot\asplistings\_database\asplistings_ac cess2000.mdb;Driver={Microsoft Access Driver (*.mdb)};UID=Admin;Password=temp"
Another option would be to simply remove the password from the database using MSACCESS.. then try to connect to it using a System DSN without the password. If your host is storing the databases outside of your web in the root of the server then removing the password on the database is not that bad of a thing to do as there is no way anyone will be able to dload it from your site. Of course there is a still a performace loss when using a system dsn with an Access Database
cwilliams38145.8540509259, Ok.. glad you got it working., Perfect exactly what I was looking for.
Thanks
,
Timecard Entry: 3/25/2006 4:47:07 PM
starting to pick up, getting busier, Setup and confgure O'Reilly WebSite Pro, work on OSICOM routers for T1 to CREG, lunch with Michele, E-mail catch-up, web design for thousand islands, Go over w/ Andy the tasks I needed done in Ogdensburg and also go over the Jeff Jacobs deal we knew nothing about., lunch, BARTER: Burlington P&R: research site spec and develop sitemap for development, Escalated a form and called Seth because of the D.C. number being down (all 4 of them), cleaning of switch room, talked to howard about marketing process, clean up disk space on COOP Linux router, billing for memorized transactions/hosting, made image for Matt and published on web page, had to reinstall some corrupted programs on my computer, searched for font for fastenmate site (found on Corel CD), techcalls, online issues and Radlog, sorted the mail /watertown mail too and did SCU deductions, Posted some acct no mail today a holiday. ans phones and general cleical officeduties, Confrm Sithe energies order w/ Cortel, annoying phone calls from Jim Crowley started today, and trying to cordinate w/ Chris B. Renzi's multiplatform proposal., Working on monthly payment calculation for reseller site, Talked to Nic about the Albany contract, revenue, etc., Pretty busy... spent an hour and a half with a customer who's modem was declared DOA by Andy after an hour of testing many different strings., Problem w/ Burlington. Talked w/ Christopher at Vermont Internet. Checking and troubleshooting a few routing issues, solved., reformatting and reinstalling Windows on computer, working on channel site, checking access numbers on web page, updating staff info page, working on ppt presentation for Jim, talking with karen at chamber regarding web site...unfinished pieces and making it live, resolved billing issues for chamber guide..., DSL Vender Effecient Networks, presentation, weekly cancels and chased Paul down to confirm the John Adee meeting in morning,