Classic ASP docs for OpenID implementation?

949 views
Skip to first unread message

BCK

unread,
Sep 3, 2010, 10:59:54 AM9/3/10
to DotNetOpenAuth
Is there any additional documentation for implementing the Classic ASP
sample (OpenIdRelyingPartyClassicAsp)? Since I'm less than ignorant
about .NET fundamentals, my language of necessity is Classic ASP. But
I'm having a hard time getting even the sample implemented in a public
test environment.

I keep getting the error, "No OpenID endpoint found" and I suspect
it's because I need to change one or more of the URL's in the sample.

I'm testing whether or not I can authenticate with my Gmail account
against Google as the provider. I won't be accessing any Google
services other than using OpenID to validate user access.

Uggg. I've spent many, many hours with RTFM, but am not able to
translate the information I find about .NET implementation into
suitable Classic ASP concepts I can understand.

Øyvind Sean Kinsey

unread,
Sep 3, 2010, 2:24:01 PM9/3/10
to dotnet...@googlegroups.com
If you are able to use .net, then do it - the API provided by the COM server will never be as nice as the 'native' one.
Just so you know, going from pure procedural ASP Classic to ASP.net isn't to hard. In many cases it can be as easy as changing the extension to .aspx, and then specify the types.

--
You received this message because you are subscribed to the Google Groups "DotNetOpenAuth" group.
To post to this group, send email to dotnet...@googlegroups.com.
To unsubscribe from this group, send email to dotnetopenid...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/dotnetopenid?hl=en.


Andrew Arnott

unread,
Sep 3, 2010, 8:00:20 PM9/3/10
to dotnetopenid
What are you typing in as the OpenID Identifier?
(little details like that can help us diagnose why DotNetOpenAuth reports an error about an Identifier. :)
--
Andrew Arnott
"I [may] not agree with what you have to say, but I'll defend to the death your right to say it." - S. G. Tallentyre

BCK

unread,
Sep 4, 2010, 12:43:59 PM9/4/10
to DotNetOpenAuth
I eventually got the sample to work, but only through hours of trial
and error. There's not a lot of documentation for the classic asp
code. The source wasn't much help to me as I'm not a .NET developer so
the actual package from http://www.dotnetopenauth.net/ ("download
version 3.4.5 now") is what I downloaded.

I put the sample from "\DotNetOpenAuth-3.4.5.10202\Samples
\OpenIdRelyingPartyClassicAsp" on my public server and followed the
instructions found in default.asp. However, there are some issues that
need to be looked at. It's possible no one really expected someone to
put the library on a production server where classic ASP was being
used. :)

1. Step number 2 in default.asp tells you to register the library as a
COM server. Fine, but the error message I get is that there's a
required assembly missing... "System.IO.FileNotFoundException: Could
not load file or assembly 'System.Web.Mvc". I found the missing file
in a different folder and copied it into the same directory as the
dotnetopenauth.dll. Re-ran the command and it registered fine.

2. Step 3 on the default.asp page tells you to add it to the assembly.
I think there's an assumption here that the library is being used
strictly from a development environment. On a fully patched W2003
server that would not have any SDK's, there are two instances of the
executable "gacutil" one of which is the DLL cache. Adding the DNOA
library to the assembly by running "C:\WINDOWS\Microsoft.NET\Framework
\v1.1.4322\gacutil.exe /i <path>\dotnetopenauth.dll" produces the
following error: "Failure adding assembly to the cache: Unknown
Error". After a bit of research, I found out that I could just drag-n-
drop the library from it's location into "C:\windows\assembly". After
an iisreset, I'm in business and the objects are being instantiated
perfectly.

3. I'll admit to knowing very little about OpenID / OpenAuth. I've
spent countless numbers of hours in months past reading about it and
as best I can tell, it's a highly fragmented "standard" with either
too much documentation in the finite details or too little common
sense documentation intelligent, quasi-programmers can follow. In any
event, when login.asp loads, I see the text box and button indicating
that I should "login". Put an email address in the box and click the
button and the trapped error that comes back is "No OpenID endpoint
found". Now... this one screwed with my head for a long time, at least
a few hours. And it wasn't until I finally realized that I wasn't
going to find an answer that I decided to post a question, my first
one, on stackoverflow. When I went to create an account on
stackoverflow, it hit me what was probably supposed to be in that
login box (and you know exactly what I'm talking about). So, instead
of putting an email address in there, I put the URL of the Google
OpenID provider (https://www.google.com/accounts/o8/id) and the sample
finally started working. This should have been documented better.

The above three items are simply my experience trying to get the
sample to work. You guys may or may not consider this (in terms of
documentation) when you update the code for the next release.

So.... where am I at now?

I'm mucking with the code a bit and, at the moment, am trying to
figure out how to get the user's email address back from the Google
provider, so I can create an account for them on my own site. I read a
post somewhere that stated because Google doesn't support a particular
method of the OpenID framework, I will never get back an email
address. However Google clearly supports *a* method for returning the
email address (see sample code requests at bottom...
http://code.google.com/apis/accounts/docs/OpenID.html), so I'm trying
to figure out how to codger a solution together.

There ya go. In a nutshell. Sorry for the lengthy message, but I
figure more detail is better than too little.

On Sep 3, 5:00 pm, Andrew Arnott <andrewarn...@gmail.com> wrote:
> What are you typing in as the OpenID Identifier?
> (little details like that can help us diagnose why DotNetOpenAuth reports an
> error about an Identifier. :)
> --
> Andrew Arnott
> "I [may] not agree with what you have to say, but I'll defend to the death
> your right to say it." - S. G. Tallentyre
>
> On Fri, Sep 3, 2010 at 11:24 AM, Øyvind Sean Kinsey <oyv...@kinsey.no>wrote:
>
> > If you are able to use .net, then do it - the API provided by the COM
> > server will never be as nice as the 'native' one.
> > Just so you know, going from pure procedural ASP Classic to ASP.net isn't
> > to hard. In many cases it can be as easy as changing the extension to .aspx,
> > and then specify the types.
>
> > Øyvind Sean Kinsey
> > oyv...@kinsey.no
> >http://kinsey.no/blog/index.php/about/
>
> > On Fri, Sep 3, 2010 at 4:59 PM, BCK <in2is...@gmail.com> wrote:
>
> >> Is there any additional documentation for implementing the Classic ASP
> >> sample (OpenIdRelyingPartyClassicAsp)? Since I'm less than ignorant
> >> about .NET fundamentals, my language of necessity is Classic ASP. But
> >> I'm having a hard time getting even the sample implemented in a public
> >> test environment.
>
> >> I keep getting the error, "No OpenID endpoint found" and I suspect
> >> it's because I need to change one or more of the URL's in the sample.
>
> >> I'm testing whether or not I can authenticate with my Gmail account
> >> against Google as the provider. I won't be accessing any Google
> >> services other than using OpenID to validate user access.
>
> >> Uggg. I've spent many, many hours with RTFM, but am not able to
> >> translate the information I find about .NET implementation into
> >> suitable Classic ASP concepts I can understand.
>
> >> --
> >> You received this message because you are subscribed to the Google Groups
> >> "DotNetOpenAuth" group.
> >> To post to this group, send email to dotnet...@googlegroups.com.
> >> To unsubscribe from this group, send email to
> >> dotnetopenid...@googlegroups.com<dotnetopenid%2Bunsu...@googlegroups.com>
> >> .
> >> For more options, visit this group at
> >>http://groups.google.com/group/dotnetopenid?hl=en.
>
> > --
> > You received this message because you are subscribed to the Google Groups
> > "DotNetOpenAuth" group.
> > To post to this group, send email to dotnet...@googlegroups.com.
> > To unsubscribe from this group, send email to
> > dotnetopenid...@googlegroups.com<dotnetopenid%2Bunsu...@googlegroups.com>
> > .

Øyvind Sean Kinsey

unread,
Sep 4, 2010, 1:00:28 PM9/4/10
to dotnet...@googlegroups.com
This might come of as a bit harsh, but really isn't meant to be so..
If you insist on continuing with classic ASP instead of taking the time to upgrade, then you should at least be familiar with working with COM-servers. Registering them aren't exactly rocket science.

3. I'll admit to knowing very little about OpenID / OpenAuth.

If you know little of it, why are you implementing it? And why would you implement it on a production server without knowing what it is/does?
I suggest you start by reading up on it - it really isn't to hard to grasp.
 
I've
spent countless numbers of hours in months past reading about it and
as best I can tell, it's a highly fragmented "standard" with either
too much documentation in the finite details or too little common
sense documentation intelligent, quasi-programmers can follow. In any
event, when login.asp loads, I see the text box and button indicating
that I should "login". Put an email address in the box and click the
button and the trapped error that comes back is "No OpenID endpoint
found".
 
I would expect this error from a user, but not from a developer implementing it.
 
Now... this one screwed with my head for a long time, at least
a few hours. And it wasn't until I finally realized that I wasn't
going to find an answer that I decided to post a question, my first
one, on stackoverflow. When I went to create an account on
stackoverflow, it hit me what was probably supposed to be in that
login box (and you know exactly what I'm talking about). So, instead
of putting an email address in there, I put the URL of the Google
OpenID provider (https://www.google.com/accounts/o8/id) and the sample
finally started working. This should have been documented better.

The above three items are simply my experience trying to get the
sample to work. You guys may or may not consider this (in terms of
documentation) when you update the code for the next release.
I beg to differ - if you don't *know* what a valid OpenID is, then you shouldn't be implementing it.

All in all, I would probably go for a asp.net > asp bridge on your server instead of try to do this in classic asp - it's little more than a shared storage, or some simple redirection using a shared secret for signing the messages..

Sean

BCK

unread,
Sep 4, 2010, 1:28:43 PM9/4/10
to DotNetOpenAuth
> This might come of as a bit harsh, but really isn't meant to be so..
>

There is only one way to interpret your arrogant response.

> If you insist on continuing with classic ASP instead of taking the time to
> upgrade, then you should at least be familiar with working with COM-servers.
> Registering them aren't exactly rocket science.
>

My need to use classic ASP is one of necessity and not one of choice.
If you insist on including a COM interface for a 15-year old
programming language, you should at least consider the audience you
are working with and provide documentation that is not only accurate,
but complete, to say nothing of putting the proper supporting
libraries in the correct locations instead of making me hunt for it.
Seems that would be non-rocket science as well.

> If you know little of it, why are you implementing it? And why would you
> implement it on a production server without knowing what it is/does?
> I suggest you start by reading up on it - it really isn't to hard to grasp.
>
> I would expect this error from a user, but not from a developer implementing
> it.
>
> I beg to differ - if you don't *know* what a valid OpenID is, then you
> shouldn't be implementing it.
>

So this is what you have to offer? You waste your time, and mine, to
insult me over and over again when I have come here looking for help
and to provide feedback for the documentation on the latest release? I
know why I'm implementing it. I know what I need to use it for and
what benefits the technology provides to me. Your responses provide
*NOTHING* of value and contribute *ZERO* substance to the question.

Here's some free advice... if you don't have anything to offer that
actually helps, move along.

Troll!

Øyvind Sean Kinsey

unread,
Sep 4, 2010, 1:41:58 PM9/4/10
to dotnet...@googlegroups.com
On Sat, Sep 4, 2010 at 7:28 PM, BCK <in2i...@gmail.com> wrote:
> This might come of as a bit harsh, but really isn't meant to be so..
>

There is only one way to interpret your arrogant response.

I'm sorry you feel that way, it was never my intention to sound arrogant. If so I wouldn't started out the way I did.
 

> If you insist on continuing with classic ASP instead of taking the time to
> upgrade, then you should at least be familiar with working with COM-servers.
> Registering them aren't exactly rocket science.
>

My need to use classic ASP is one of necessity and not one of choice.
I was basing my comment on your earlier statement

On Sep 3, 4:59 pm, BCK <in2is...@gmail.com> wrote:
Since I'm less than ignorant  
 about .NET fundamentals, my language of necessity is Classic ASP
It came across that your 'necessity' was based on your 'ignorance', hence my reaction. 

If you insist on including a COM interface for a 15-year old
programming language, you should at least consider the audience you
are working with and provide documentation that is not only accurate,
but complete, to say nothing of putting the proper supporting
libraries in the correct locations instead of making me hunt for it.
Seems that would be non-rocket science as well.

I'll suggest for Andrew that the remove the support - satisfied? 

> If you know little of it, why are you implementing it? And why would you
> implement it on a production server without knowing what it is/does?
> I suggest you start by reading up on it - it really isn't to hard to grasp.
>
> I would expect this error from a user, but not from a developer implementing
> it.
>
> I beg to differ - if you don't *know* what a valid OpenID is, then you
> shouldn't be implementing it.
>

So this is what you have to offer? You waste your time, and mine, to
insult me over and over again when I have come here looking for help
and to provide feedback for the documentation on the latest release? I
know why I'm implementing it. I know what I need to use it for and
what benefits the technology provides to me.
It was only a hint towards reading the docs, understanding the spec (or at least the feature set), and then attempting to implement it.
 
Your responses provide
*NOTHING* of value and contribute *ZERO* substance to the question.

Here's some free advice... if you don't have anything to offer that
actually helps, move along.

Troll!
I was really not expecting such a strong response, I was actually giving advice, and as I try to treat 'Senior System Engineer's as children, I was giving this straight up.

I'm sorry if I have offended you, but there you have it.

Sean

Andrew Arnott

unread,
Sep 4, 2010, 5:02:03 PM9/4/10
to dotnetopenid
Wow, ok so coming in here a bit late...

Thanks for the feedback BCK (Brian, may I assume?).  Very few people use the classic ASP OpenID RP as you can imagine, so we don't get much feedback on it.  I certainly don't use it aside from testing it, and since I know OpenID forwards and backwards, I sometimes forget what information would be good to include to help people in your situation.

I've added several lines of comments to the login.asp file.  After reading your StackOverflow question I realized even I had to study the code hard all over again to understand what it did.  The comments should help in the next release.  I've also added some more details to the default.asp file to help guide future users to using the correct version of gacutil.exe, and where they might find the other DLLs.  

I'll just throw in there, that "complete" documentation is a difficult amount of docs to agree on.  And considering that this whole thing is provided to you as free software, anything you get should be taken as such -- if it's better than worthless, that's a bonus. :)  But I am proud of this library and all the work that's gone into it, so I strive to make it the best it can be.  Again, I appreciate your feedback. And I'm glad you have it working now.

Finally, regarding Google and email addresses, Google requires the use of the AX extension, which the COM Server shim does not (directly) support.  It can be done but is really tricky.  More can be done in this area.  Please add a request item to http://dotnetopenauth.uservoice.com/ so I don't forget.


--
Andrew Arnott
"I [may] not agree with what you have to say, but I'll defend to the death your right to say it." - S. G. Tallentyre


2010/9/4 Øyvind Sean Kinsey <oyv...@kinsey.no>

--
You received this message because you are subscribed to the Google Groups "DotNetOpenAuth" group.
To post to this group, send email to dotnet...@googlegroups.com.
To unsubscribe from this group, send email to dotnetopenid...@googlegroups.com.

Andrew Arnott

unread,
Sep 4, 2010, 10:38:17 PM9/4/10
to dotnetopenid
I take it back.  The classic ASP COM server in DotNetOpenAuth v3.4.5 does actually enable you to get a Google user's email address.  You do need to modify the sample slightly:

-redirectUrl = dnoi.CreateRequestWithSimpleRegistration(Request.Form("openid_identifier"), realm, thisPageUrl, "nickname,email""fullname")
+redirectUrl = dnoi.CreateRequestWithSimpleRegistration(Request.Form("openid_identifier"), realm, thisPageUrl, """email")
This should do it.  If not, it may be that Google requires RP discovery to succeed.  RP Discovery is a good thing to make work anyway.  The directions to do it are at http://blog.nerdbank.net/2008/06/why-yahoo-says-your-openid-site.html.  Note though that classic ASP wasn't the audience I had in mind when writing the post, so you may need to adapt some techniques a bit.
--
Andrew Arnott
"I [may] not agree with what you have to say, but I'll defend to the death your right to say it." - S. G. Tallentyre


Brian Kelley

unread,
Sep 5, 2010, 1:27:19 AM9/5/10
to dotnet...@googlegroups.com
This is great Andrew. I'll give this a shot a little later.

Considering you don't get a lot of feedback on the Classic ASP side of this library, this might be a complete waste of time. But... I was thinking that the only real thing I was missing was an indication of the classes or methods that had been exposed in the COM wrapper for us old-schoolers. I recall reading something about the items that were exposed to Classic ASP was extremely limited, but usable. But... if I know what methods / properties *were* exposed, I (and others) could probably figure the rest of it on my own. Does that make any sense?

See... now I'm actually looking at the lines you offered below and I'm thinking to myself, "Geeze. I didn't even know I could use 'CreateRequestWithSimpleRegistration".

Also, one other thing, I read that Google *MAY* return a response with either a POST or a GET and that the programmer should be prepared to handle each situation as appropriate. It was in their documentation though some of the samples I've seen for dnoi are definitely looking for responses in the form object. Don't know if this info is irrelevant to you or if you've already covered it, or if what I'm saying makes so little sense that you are scratching your head.


On Sat, Sep 4, 2010 at 7:38 PM, Andrew Arnott <andrew...@gmail.com> wrote:
I take it back.  The classic ASP COM server in DotNetOpenAuth v3.4.5 does actually enable you to get a Google user's email address.  You do need to modify the sample slightly:

-redirectUrl = dnoi.CreateRequestWithSimpleRegistration(Request.Form("openid_identifier"), realm, thisPageUrl, "nickname,email""fullname")
+redirectUrl = dnoi.CreateRequestWithSimpleRegistration(Request.Form("openid_identifier"), realm, thisPageUrl, """email")
This should do it.  If not, it may be that Google requires RP discovery to succeed.  RP Discovery is a good thing to make work anyway.  The directions to do it are at http://blog.nerdbank.net/2008/06/why-yahoo-says-your-openid-site.html.  Note though that classic ASP wasn't the audience I had in mind when writing the post, so you may need to adapt some techniques a bit.
--


-Brian

Andrew Arnott

unread,
Sep 5, 2010, 10:04:51 AM9/5/10
to dotnetopenid
Hi Brian,

Thanks.  Ovynd has been the one guy on this list besides me to take time out of his day to respond to questions.  Usually he does pretty well -- he knows the library pretty well.  Sometimes he comes off a bit more scathing than I'd like, but I do believe his motives are usually in the right place.  On one point, your use of classic ASP, I'm sure no one uses it by choice these days, so I assumed your hands were tied.

I don't know if this will help you (and yes, docs would be good here) but you can read the public surface area of the COM server across the three files in this directory:

Yes, Google as well as any other OP may legitimately send back a 301 Redirect or a form POST.  DNOA can absolutely handle either one.  And in fact the classic ASP sample also supports it, like this:

	requestUrl = "http://" + Request.ServerVariables("HTTP_HOST") + Request.ServerVariables("HTTP_URL")
Set dnoi = server.CreateObject("DotNetOpenAuth.OpenId.RelyingParty.OpenIdRelyingParty")
On Error Resume Next
Set authentication = dnoi.ProcessAuthentication(requestUrl, Request.Form)
The requestUrl that you pass in takes care of the 301 Redirect "GET" case, and the Request.Form that you pass in takes care of the form POST case.  DNOA internally figures out which one is happening and just does the right thing.

--
Andrew Arnott
"I [may] not agree with what you have to say, but I'll defend to the death your right to say it." - S. G. Tallentyre


--

dfriedmann

unread,
Oct 14, 2010, 3:57:21 PM10/14/10
to DotNetOpenAuth
Hi guys,
you have been doing a great job with this project and the support.
I just tried out the latest version on a classic asp project and it
worked like a charm (given the instructions in the default.asp sample
file).
Great job!

Andrew Arnott

unread,
Oct 14, 2010, 8:17:07 PM10/14/10
to dotnet...@googlegroups.com

Thanks. It's nice to get positive reinforcement.

Reply all
Reply to author
Forward
0 new messages