Answers.Body: <p>I believe you have found <a href="https://civicrm.org/extensions/civihoneypot" rel="nofollow noreferrer">this</a> honeypot extension. (According to the documentation this one could be used for protecting the contribution forms.)</p>
  <p>As far as i see, it uses <a href="https://docs.civicrm.org/dev/en/latest/hooks/list/" rel="nofollow noreferrer">hooks</a> for extending the from and validation logic. It implements the <a href="https://docs.civicrm.org/dev/en/latest/hooks/hook_civicrm_buildForm/" rel="nofollow noreferrer">build form</a> hook <a href="https://github.com/elisseck/com.elisseck.civihoneypot/blob/master/civihoneypot.php#L31-L87" rel="nofollow noreferrer">here</a> and the <a href="https://docs.civicrm.org/dev/en/latest/hooks/hook_civicrm_validateForm/" rel="nofollow noreferrer">validate form</a> hook <a href="https://github.com/elisseck/com.elisseck.civihoneypot/blob/master/civihoneypot.php#L93-L122" rel="nofollow noreferrer">here</a>.</p>
  <p>If i understand you well, you want to protect the profile forms with the honeypot solution.</p>
  <p>The profile form is build in a different way, so that the hooks above can not be used here. Instead of them the <a href="https://docs.civicrm.org/dev/en/latest/hooks/hook_civicrm_buildProfile/" rel="nofollow noreferrer">build profile</a> and <a href="https://docs.civicrm.org/dev/en/latest/hooks/hook_civicrm_validateProfile/" rel="nofollow noreferrer">validate profile</a> hooks are triggered, so that you should implement them.</p>
  <p>The civihoneypot extension provides a settings page where you can select the forms that you want to protect. I believe this settings form has to be extended also to be able to select profiles. The setting form is constructed <a href="https://github.com/elisseck/com.elisseck.civihoneypot/blob/master/CRM/Civihoneypot/Form/HoneypotSettings.php#L37-L77" rel="nofollow noreferrer">here</a>. I think the only thing that needs to be done here is adding a new entityref for uf_groups (those are the profiles), and the advcheckbox for the select all feature.</p>
  <p>I hope it helps you.</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2021-07-23T08:14:09.613Z
Answers.Text: Thank you for your suggestions. Yes, the mentioned extension is the one. I give it a try.
  Unfortunately, I am more experienced with systems and database mgmt than programming, but I will install the extension and will look into the use of the hooks. I think I have seen some documents relating to this.
Answers.UserDisplayName: B e r t
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2021-07-22T08:12:21.393Z
Answers.LastActivityDate: 2021-07-22T08:12:21.393Z
Answers.UserDisplayName: akosgarai
Answers.Body: <p>In summary (i think) the honeypot extension currently works with Contribution pages. This <a href="https://github.com/elisseck/com.elisseck.civihoneypot/pull/5" rel="nofollow noreferrer">pull</a> extends it for Membership and Event pages, but does not yet work with standalone Profiles. The extension developers may welcome funding to add such a feature</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2021-07-23T08:07:33.073Z
Answers.Text: Thank you, petednz. Yes, the pull describes it well, but is closed. Probably the comments of @akosgarai are useful hints for this poll.
Answers.UserDisplayName: B e r t
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2021-07-22T20:22:00.080Z
Answers.LastActivityDate: 2021-07-22T20:22:00.080Z
Answers.UserDisplayName: petednz - fuzion
Body: <p>We have unlike may others no spam problems with contributions, however the spam entry via the contact for got annoying. As well there is no problem with joomla-profile generation as this functionality is disabled.</p>
  <p>The &quot;contact form&quot; profile has reCaptcha V2 enabled, however a specific spam bot network seems to be able to emulate human interaction. I say specific as the entries are similar and point to a specific source. I/P blocking does not work as I/P is changing, so I look for other solutions for our NGO.</p>
  <p>I found no hint how to add a profile field whose result can be compared with a given value to prevent the form from being sent if false.</p>
  <p>I found some honeypot instructions for contribution forms, but are not aware what files need to be modified for the contact form and how such coding may interact with update mechanisms. (over-writing)</p>
  <p>So, if you have a tip, I will be glad to follow. Thank you.</p>
  
Tags: <profile><spam>
Title: Looking for a description to add honeypot fields to the "Contact Form"
ThreadText: # Looking for a description to add honeypot fields to the "Contact Form"
  
  (Asked by: username_0 on 2021-07-22)
  
  We have unlike may others no spam problems with contributions, however the spam entry via the contact for got annoying. As well there is no problem with joomla-profile generation as this functionality is disabled.
  
  The "contact form" profile has reCaptcha V2 enabled, however a specific spam bot network seems to be able to emulate human interaction. I say specific as the entries are similar and point to a specific source. I/P blocking does not work as I/P is changing, so I look for other solutions for our NGO.
  
  I found no hint how to add a profile field whose result can be compared with a given value to prevent the form from being sent if false.
  
  I found some honeypot instructions for contribution forms, but are not aware what files need to be modified for the contact form and how such coding may interact with update mechanisms. (over-writing)
  
  So, if you have a tip, I will be glad to follow. Thank you.
  
  **Tags:** profile, spam
  
  
  ---
  
  ## 2 answers
  
  ### Answer by username_1 on 2021-07-22. Score: 3
  
  I believe you have found [this](https://civicrm.org/extensions/civihoneypot) honeypot extension. (According to the documentation this one could be used for protecting the contribution forms.)
  
  As far as i see, it uses [hooks](https://docs.civicrm.org/dev/en/latest/hooks/list/) for extending the from and validation logic. It implements the [build form](https://docs.civicrm.org/dev/en/latest/hooks/hook_civicrm_buildForm/) hook [here](https://github.com/elisseck/com.elisseck.civihoneypot/blob/master/civihoneypot.php#L31-L87) and the [validate form](https://docs.civicrm.org/dev/en/latest/hooks/hook_civicrm_validateForm/) hook [here](https://github.com/elisseck/com.elisseck.civihoneypot/blob/master/civihoneypot.php#L93-L122).
  
  If i understand you well, you want to protect the profile forms with the honeypot solution.
  
  The profile form is build in a different way, so that the hooks above can not be used here. Instead of them the [build profile](https://docs.civicrm.org/dev/en/latest/hooks/hook_civicrm_buildProfile/) and [validate profile](https://docs.civicrm.org/dev/en/latest/hooks/hook_civicrm_validateProfile/) hooks are triggered, so that you should implement them.
  
  The civihoneypot extension provides a settings page where you can select the forms that you want to protect. I believe this settings form has to be extended also to be able to select profiles. The setting form is constructed [here](https://github.com/elisseck/com.elisseck.civihoneypot/blob/master/CRM/Civihoneypot/Form/HoneypotSettings.php#L37-L77). I think the only thing that needs to be done here is adding a new entityref for uf\_groups (those are the profiles), and the advcheckbox for the select all feature.
  
  I hope it helps you.
  
  > **Comments:**
  > **username_0**: Thank you for your suggestions. Yes, the mentioned extension is the one. I give it a try. Unfortunately, I am more experienced with systems and database mgmt than programming, but I will install the extension and will look into the use of the hooks. I think I have seen some documents relating to this.  
  
  ---
  
  ### Answer by username_2 on 2021-07-22. Score: 2
  
  In summary (i think) the honeypot extension currently works with Contribution pages. This [pull](https://github.com/elisseck/com.elisseck.civihoneypot/pull/5) extends it for Membership and Event pages, but does not yet work with standalone Profiles. The extension developers may welcome funding to add such a feature
  
  > **Comments:**
  > **username_0**: Thank you, username_2. Yes, the pull describes it well, but is closed. Probably the comments of @username_1 are useful hints for this poll.  
  
  ---
  
  