Security

Reply
Contributor I
Posts: 28
Registered: ‎05-31-2016

Guest Sponsorship Validity Check Question

Hi all,

 

I have recently implemented a sponsor based guest sponsorship system. The only disadvantage is that I have been asked to use the non-authenticated sponsor email confirmation instead of making the sponsors log in.

 

I have restricted the sponsor emails so that they must be from our domain, however, students have the same domain. I would like to be able to restrict them from being able to sponsor themselves.

 

All student email addresses are in the format of 'aabbbbbb55@domain.com' (first 2 initials, up to 6 of last name, and two digits)

 

Is there a way to restrict this format via the validity checker?

 

Thanks,

--Ben

MVP
Posts: 951
Registered: ‎04-13-2009

Re: Guest Sponsorship Validity Check Question

[ Edited ]

Just change the doman from gmail.com to your domain:

 

^[A-Za-z]+[0-9]{2}@gmail.com

 

Insert it as below in the sponsor email field (assuming you're using that one) and set the validator to IsRegexMatch.

 

regex.jpg

 

Edit: removed the 0-9 from the first part of the regex.

Cheers
James

-------------------------------------------------------
-------------------@whereisjrw-------------------
------------------------blog-------------------------
ACCX #540 | ACMX #353 | ACDX #216
-----------Mobility First Expert #11----------
-------------------------------------------------------

If a reply adequately addresses your issue, please click on the "Accept as Solution" and "Give Kudos" button so this information can benefit other users via search.
Contributor I
Posts: 28
Registered: ‎05-31-2016

Re: Guest Sponsorship Validity Check Question

Changing the validator to regex would drop my current domain restrictions correct?

 

If so, can I add multiple regex statements?

MVP
Posts: 951
Registered: ‎04-13-2009

Re: Guest Sponsorship Validity Check Question

A single regex would work.

 

E.g. the following regex will match any number of a-z characters @ gmail.com anbd ggg.com.

 

^[A-Za-z]*@(([g][m][a][i][l])|([g][g][g])).com

 

I would recommend checking out the following regex site to learn how to use regex expressions. https://regex101.com/

Cheers
James

-------------------------------------------------------
-------------------@whereisjrw-------------------
------------------------blog-------------------------
ACCX #540 | ACMX #353 | ACDX #216
-----------Mobility First Expert #11----------
-------------------------------------------------------

If a reply adequately addresses your issue, please click on the "Accept as Solution" and "Give Kudos" button so this information can benefit other users via search.
Search Airheads
Showing results for 
Search instead for 
Did you mean: