It really is best to write your own. Depending on the nature of the environment from which users will be accessing the site (i.e. home v.s. public library or school computer lab), you can decide to use cookies or not.
The basics:
start a PHP session: session_start();
do on every page.
do this before any output on the page if you're using cookies
on the login page: use forms for username and password and have the target page check the $POST[username] and $POST[pw] against whatever you have - flat file, hard-coded, or database.
if the name/pw are good, create session variables to track whether or not the person is a valid user (track username or userid).
With logout, use session_destroy() and probably unset() functions (session_destroy I think is required, don't remember if unset is or not - it's been a while since I wrote any authentication programs).