> Now to update my blog post.
Do you mind sharing that blog post ? :)
Derek
--
Derek Wuelfrath
[email protected] :: +1.514.447.4918 (x110) :: www.inverse.ca
Inverse inc. :: Leaders behind SOGo (www.sogo.nu) and PacketFence
(www.packetfence.org)
On 2013-07-25, at 10:43 AM, "Bulanda, Dave G" <[email protected]> wrote:
> Thanks Derek.
>
> I was able to add that to the custom.pm and roll back the code change in
> guest.pm. And like magic it works.
>
> That is why I posted it back to know if there was a better method to add that
> change in.
>
> Now to update my blog post.
>
> Thanks
>
> Dave
>
>
> David Bulanda
> Network Services Manager
> [email protected]
> Indiana Tech
>
>
>
> From: Derek Wuelfrath [mailto:[email protected]]
> Sent: Wednesday, July 24, 2013 2:59 PM
> To: [email protected]
> Subject: Re: [PacketFence-users] Guest Portal - Email Domain Blocking
>
> Dave,
> To be sure that change is not written over when upgrading PacketFence, you
> should use the extension point that you'll find in lib/pf/web/custom.pm
>
> Documentation is part of that file and that way, you'll be sure not to
> diverge from the original code base.
>
> Cheers!
> dw.
>
> --
> Derek Wuelfrath
> [email protected] :: +1.514.447.4918 (x110) :: www.inverse.ca
> Inverse inc. :: Leaders behind SOGo (www.sogo.nu) and PacketFence
> (www.packetfence.org)
>
> On 2013-07-23, at 8:18 PM, "Bulanda, Dave G" <[email protected]>
> wrote:
>
>
> Fabrice,
>
> In the guest.pm I was able to just copy the If statement and create a second
> check for the second domain that I was wanting to block. See below:
>
> my $email_type =
> pf::Authentication::Source::EmailSource->meta->get_attribute('type')->default;
> my $source =
> &pf::authentication::getAuthenticationSourceByType($email_type);
> if ($source) {
> unless (isenabled($source->{allow_localdomain})) {
> # You should not register as a guest if you are part of the local
> network
> my $localdomain = $Config{'general'}{'domain'};
>
> # Added explicated second domain for check below
>
> my $localdomain1 = ‘second domain name’;
>
> if ($cgi->param('email') =~ /[@.]$localdomain$/i) {
> return ($FALSE, $GUEST::ERROR_EMAIL_UNAUTHORIZED_AS_GUEST, [
> $localdomain ]);
> }
>
> if ($cgi->param('email') =~ /[@.]$localdomain1$/i) {
> return ($FALSE, $GUEST::ERROR_EMAIL_UNAUTHORIZED_AS_GUEST, [
> $localdomain1 ]);
> }
> }
> }
>
>
> I know it’s not pretty and maybe not the best programming method but it does
> work.
>
> Thanks for the point in the right direction.
>
>
> David Bulanda
> Network Services Manager
> [email protected]
> Indiana Tech
>
>
>
> From: Fabrice DURAND [mailto:[email protected]]
> Sent: Monday, July 22, 2013 9:03 AM
> To: [email protected]
> Subject: Re: [PacketFence-users] Guest Portal - Email Domain Blocking
>
> Hello,
> yes you can do it, in guest.pm in the function validate_sponsor packetfence
> try to verify if only the local domain email address can sponsor guest access
> if sponsors_only_from_localdomain is enaled.
> If it´s not enabled then it try to test
> $authenticator->isAllowedToSponsorGuests(
> lc($portalSession->cgi->param('sponsor_email')) ) . So if in your
> authentication source isAllowedToSponsorGuests return True then it will work.
>
> Regards
> Fabrice
>
> Le 2013-07-22 05:59, Anton Dreyer a écrit :
> Hi
>
> I would also like to know if this is possible – specifying a custom domain(s)
> Running pf3.61
>
> Thanks
>
> Anton Dreyer
>
> From: Bulanda, Dave G [mailto:[email protected]]
> Sent: 18 July 2013 04:03 PM
> To: [email protected]
> Subject: [PacketFence-users] Guest Portal - Email Domain Blocking
>
> Under Guest self-registration you can block the email address from the
> local domain registering. Is there a way to add another domain?
>
> Thanks
>
> David Bulanda
> Network Services Manager
> [email protected]
> Indiana Tech
>
>
>
>
>
>
> ------------------------------------------------------------------------------
> See everything from the browser to the database with AppDynamics
> Get end-to-end visibility with application monitoring from AppDynamics
> Isolate bottlenecks and diagnose root cause in seconds.
> Start your free trial of AppDynamics Pro today!
> http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk
>
>
>
>
> _______________________________________________
> PacketFence-users mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/packetfence-users
>
>
>
>
> --
> Fabrice Durand
> [email protected] :: +1.514.447.4918 (x135) :: www.inverse.ca
> Inverse inc. :: Leaders behind SOGo (http://www.sogo.nu) and PacketFence
> (http://packetfence.org)
> ------------------------------------------------------------------------------
> See everything from the browser to the database with AppDynamics
> Get end-to-end visibility with application monitoring from AppDynamics
> Isolate bottlenecks and diagnose root cause in seconds.
> Start your free trial of AppDynamics Pro today!
> http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk_______________________________________________
> PacketFence-users mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/packetfence-users
>
> ------------------------------------------------------------------------------
> See everything from the browser to the database with AppDynamics
> Get end-to-end visibility with application monitoring from AppDynamics
> Isolate bottlenecks and diagnose root cause in seconds.
> Start your free trial of AppDynamics Pro today!
> http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk_______________________________________________
> PacketFence-users mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/packetfence-users
------------------------------------------------------------------------------
See everything from the browser to the database with AppDynamics
Get end-to-end visibility with application monitoring from AppDynamics
Isolate bottlenecks and diagnose root cause in seconds.
Start your free trial of AppDynamics Pro today!
http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk
_______________________________________________
PacketFence-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/packetfence-users