1

When I follow the instructions in pset7 and i enter https://ide50-username.cs50.io/ where username is my username i dont get to cs50 finace login page, but instead I get to a page that tells me the following:

Warning: Unknown: failed to open stream: Permission denied in Unknown on line 0

Fatal error: Unknown: Failed opening required '/home/ubuntu/workspace/pset7/public/index.php' (include_path='.:/usr/share/php:/usr/share/pear') in Unknown on line 0

I followed the instructions, what is happening? Thanks for advice!

1

The "403 Forbidden" error has to do with the permissions on your files and folders. The minimum permissions necessary for pset7 and pset8 have changed, and the problem specifications have not been updated to reflect the new permissions.

See 403 Forbidden / permissions / chmod -- the definitive guide on the CS50 Reddit, for details on the minimum required permissions for different types of file.

TL;DR:

  • It's 711 for directories (unless you want Apache2 to generate a dynamic index when there is no index.html or index.php provided, then it's 755).
  • It's 644 for most everything else -- HTML, CSS, image and font files.
  • For PHP files and JSON files, you can lock permissions down to 640 (and outside the CS50 IDE, you may even be able to lock them down to 600).
  • Finally, you may have files and directories in your problem set directory that you don't want to share online at all (as with ./bin/import in Problem Set 8) and for these files, you should restrict permissions to 700.

If this answers your question, be sure to accept it by clicking on the green check mark. Otherwise, it will remain marked as unanswered and haunt the forum forever as a Zombie Question.

| improve this answer | |

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .