Welcome Guest, Not a member yet? Register   Sign In
.htaccess application folder - 403 forbidden access
#1

Hello ! 

I currently develop a website with CodeIgniter. I use the localhost. 
I'm facing to a problem with the .htaccess file from application directory. 

I develop the Stripe API (payment method) on my website. The Stripe API propose a Webhook system. Webhook give the possibility to inform the website when event occurs. For example when a payment was succeeded, Stripe send a Webhook to execute a php script on my server. 


As I work with localhost, I use the tool Ultrahook who allow me to receive Webhook from Stripe on localhost. So I would like to execute a PHP script on my application/controllers/ folder when I receive a Webhook from Stripe. 

When I try do it, I always receive a 403 error forbidden access for the application folder. So I have try to modify the .htaccess from application folder but without positive result. My initial .htaccess from application folder look like this : 


Code:
<IfModule authz_core_module>
   Require all denied
</IfModule>
<IfModule !authz_core_module>
   Deny from all
</IfModule>



Stripe documentation give me some IP address for Webhooks. 

The full list of IP addresses that webhook notifications may come from is:
  • 54.187.174.169
  • 54.187.205.235
  • 54.187.216.72
  • 54.241.31.99
  • 54.241.31.102
  • 54.241.34.107
IP address use by Stripe


So I have try to allow them in .htaccess with the following code but without success. 


Code:
Require ip xx.xxx.xxx.xxx  yy.yyy.yyy.yyy ...


Do you have any idea how to configure the .htaccess in application folder to give access to Stripe to the files in the controllers folder ?
 
Thanks ! 

Samuel
Reply


Messages In This Thread
.htaccess application folder - 403 forbidden access - by sami50 - 05-11-2019, 03:31 PM



Theme © iAndrew 2016 - Forum software by © MyBB