abev
  •  abev
  • 53.6% (Neutral)
  • YAF Forumling Topic Starter
2009-11-16T20:49:36Z
What is the simplest way to integrate YAF with my current site? (short of having users create a totally different log in). I looked at the integration links and I am totally lost. Cant I just set a auth ticket from my site's log in with authenticates them to the yaf site? I can sync the database aspnet_users/membership tables and the yav_prov_membership table in the background.

Sponsor
Jaben
  •  Jaben
  • 100% (Exalted)
  • YAF Developer
2009-11-16T22:01:57Z
Take a look at Forms Authentication and ASP.NET membership. It's all standardized and YAF (and other apps) can use it perfectly.
abev
  •  abev
  • 53.6% (Neutral)
  • YAF Forumling Topic Starter
2009-11-17T08:34:00Z
Jaben wrote:

Take a look at Forms Authentication and ASP.NET membership. It's all standardized and YAF (and other apps) can use it perfectly.



But I want to use my own membership. I cannot do it this way with YAF?

I want to keep YAF and my app running separately, my app in the root and yaf in another directory running as a subdomain.
Jaben
  •  Jaben
  • 100% (Exalted)
  • YAF Developer
2009-11-17T15:08:43Z
That's fine... but I'm saying it's all a standardized API that YAF uses. You don't need to know anything "special" about YAF except that is support ASP.NET Forms authentication and membership.

The rest is up to you.
abev
  •  abev
  • 53.6% (Neutral)
  • YAF Forumling Topic Starter
2009-11-18T09:34:26Z
I guess I am missing the boat here somewhere. In my world "standardized" would mean that YAF uses the aspnet_membership tables, but it doesn't. If it did it would be a simple integration. Just point the yaf membership in webconfig to my existing webconfig and everyone is happy. Something has to change to integrate, whether I change my site or I change the YAF source code. I was hoping that someone had a simple(r) solution than whats been presented.

I would even consider moving my existing users over to the yaf membership and making them change passwords (because they cannot be recovered as they are encrypted).
Jaben
  •  Jaben
  • 100% (Exalted)
  • YAF Developer
2009-11-18T12:35:34Z
YAF can use aspnet_membership tables, yes. Just tell YAF to use ASP.NET membership providers.

But if you need backwards compatibility with your existing YAF user base, then you need to use YAF's membership due to the password incompatibility issues.

Is that your problem? I'm still confused about what is your hang up here...
abev
  •  abev
  • 53.6% (Neutral)
  • YAF Forumling Topic Starter
2009-11-18T18:03:24Z
Jaben wrote:

YAF can use aspnet_membership tables, yes. Just tell YAF to use ASP.NET membership providers.

But if you need backwards compatibility with your existing YAF user base, then you need to use YAF's membership due to the password incompatibility issues.

Is that your problem? I'm still confused about what is your hang up here...



Haha I am confused too. We're getting somewhere though...I never had YAF before on my site. I have a site with membership running aspnet membership. I can just change the <forms>, <membership>, and <role> sections in the YAF web.config to match the exact setting in my current sites web.config and I am done? (I dont use a profile provider in my current app). Does it matter that my site and YAF are running as separate apps?

It's very possible that I have made this more complicated than it should be.
abev
  •  abev
  • 53.6% (Neutral)
  • YAF Forumling Topic Starter
2009-11-19T15:52:53Z
Was far simpler than I thought - I just changed the membership, role, and db.configs to point to my existing web.config settings and everything worked great. Had to do two things first, add myself to Administrators and sync the users so all of the members got added. So far looks great! One thing I should probably do is disable the create user page from the yaf side because if they start there they wont be able to get in to fakepuppy?
Jaben
  •  Jaben
  • 100% (Exalted)
  • YAF Developer
2009-11-19T17:49:27Z
Glad you got it working...

As for login options -- depends on the version. in v1.9.3 you can disable login in the Admin->Host Settings.

In v1.9.4 you can disable login in the appSettings (<add key="YAF.AllowLoginAndLogoff" value="false" /> ) and specify a "custom" login url. :)

Good luck!
abev
  •  abev
  • 53.6% (Neutral)
  • YAF Forumling Topic Starter
2009-11-19T19:02:27Z
thanks for the help Jaben. I think I broke YAF for the moment... I synced all useres but it synced them to a 'newbie', instead of 'registered'. So useres can log in but not access anything. I am trying to find an easy way to integrate them - I think I need to add each user to the the 'registered' role in aspnet_usersinroles.

*edit yep that was it - any idea why the sync didnt behave? I am sure it has to do with my config.

About Us

The YAF.NET is an open source .NET forum project. YAF.NET is supported by an team of international developers who are build community by building community software.

Powered by Resharper Donate with PayPal button

Project Twitter Updates

Copyright © YetAnotherForum.NET & Ingo Herbote. All rights reserved