I am trying to send secure windows push notifications from my php server with valid ssl certificate and I got this error:
403 - Forbidden: Access is denied.
You do not have permission to view this directory or page using the credentials that you supplied.
I uploaded certificate to dev.windowsphone.com and HttpNotificationChannel where serviceName is my Common Name from certificate. I got https uri from HttpNotificationChannel but when I call it from server I got error. Does anyone know what the problem is?
When I call unsecure request from server everything is ok.
You will need to allow access in the directory in Apache. Assuming you have super user access to the server, and I don't know how your server is set up, but you will need to set your directory like this:
<Directory "C:/Your/Directory/With/No/Trailing/Slash">
Allow from all
Require all granted
</Directory>
Related
I have a Windows Server 2019 running web server Apache 2.4 PHP8 with user "Local System". This server is not in a Domain and I want to mantain the user "Local System" which executes the services for security reasons.
In a PHP script I want to execute scandir to a network folder "\srv-data\documents" and I want to configure Apache to use another user to access this folder.
Then:
I create the file .htpasswd with username "user.data" and relative password
I add these line into the apache configuration file:
<Directory "\\srv-data\documents\">
AuthType Basic
AuthName "Access only allowed for user.data"
AuthUserFile .htpasswd
Require user user.data
</Directory>
I restart the service.
If I try to execute the PHP script, the web server still returns "access is denied (code 5)".
The user credentials are stored into the Windows Server 2019 and the destination server and if I try to access with file explorer with "user.data" user it works, then I think it is a bad configuration on apache configuration file
Thank for you help
Best regards
Matteo
I tried to add some double quotes to reference the .htpasswd files, I tried to change something else to the configuration but it still not works.
The web server must continue to be run by the "Local Server" user and the same web server must access to the directory "\srv-data\documents" with the different user "user.data"
Hi I have my php code up and running on a server. When I enter the below url in the browser i get the content .
<ip_address_vm>/service.php
I have purchased a domain name from goDaddy and linked the domain to the ip address of the vm. But now,when i enter the below url in the browser
domain_name/service.php
I get ->
403 Forbidden
Request forbidden by administrative rules.
I dont have the administrator rights to the vm, but i can access this vm. Can someone help me with this issue.
Thanks
I'm trying to access an PHP 7.x file on a restricted webspace, but get the famous 403:
Forbidden
You don't have permission to access /path/to/file.php on this server.
After searching on StackOverflow and trying different settings, I set the CHMOD to 777, which didn't change anything.
I've no root nor apache access.
Now I'm trying to allow access via .htaccess, but no success so far:
Order Allow,Deny
Allow from all
Result: 500 - Internal Server Error.
Any idea?
Thanks in advance!
I'm trying to host a new blog where I can add posts using a simple HTML form & PHP script. When I test out the form on my localhost everything works fine, but when I upload it and test it live I get:
Forbidden
You don't have permission to access /php/add-post.php on this server.
Additionally, a 404 Not Found error was encountered while trying to
use an ErrorDocument to handle the request.
I know that my host allows this type of script because I'm using exactly the same thing on another blog, and my permissions are set to 0755. Does anyone know what the problem might be & how to solve it?
Add the below code in .htaccess file
<Files add-post.php>
Order Deny,Allow
Deny from all
Allow from all
</Files>
Or run command to provide permission to folder
chmod 774 /path/to/php/add-post.php
I have configured dotProject Project management tool with wamp server. But now I am getting 403 Access forbidden while i try to access it using ip address (http://ipaddress/). But if i use http://localhost/ i get access to it. What is the problem?
I have made changes in httpd:conf as Allow all instead of deny all.
thanks for the help
Sneha