Jump to content

Submit ticket hook


Th0m4s

Recommended Posts

Hello,

 

I'm creating my first hook for WHMCS and I really need your help.

The goal of this hook is to be able to restrict access to support department  to customers with at least one active service.

In WHMCS admin I checked "Only allow registered clients to open tickets in this department".

 

In my hook I already secured three points

 

BUT : if the customer has a bit of knowledge in dev, he could easylie inspect the code and change department id in the dropdown. It can also send a POST request to https://example.com/whmcs/submitticket.php?step=3

I tried to secure the third step but without success.

 

I use the "ClientAreaPageSubmitTicket" but when I try to do a "die();" every page (submitticket.php / submitticket.php?step=2&deptid=2) return a blank page but submitticket.php?step=3 is redirecting to clientarea.php. So, the "die()" in my hook is not applied to this page.

 

Do you know a way to perform action in my hook in this third step ?

 

Thank you for your help.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use & Guidelines and understand your posts will initially be pre-moderated