Ideally you would script out the users and permissions prior to doing the restore. If that has not happened, then you need to go about fixing things after the fact, and chances are something will be missed but you should be able to get about 90% of the way there.
The first thing you need to ascertain is if the same logins exist on the new server. If they don't then you should find out if it is OK for the logins to be created on the new server. Never assume that they should be created, there could be a good reason as to why they did not exist in the first place. You can then go about creating them by digging through the sysusers table.
You can fix the orphaned users by running something similar to the following:
DECLARE @username varchar(25), @loginsid varbinary(85)
DECLARE fixusers CURSOR
FOR
SELECT UserName = name
FROM sysusers
WHERE issqluser = 1
and (sid is not null and sid <> 0x0)
and suser_sname(sid) is null
and name in (select name from master..syslogins)
ORDER BY name
OPEN fixusers
FETCH NEXT FROM fixusers
INTO @username
WHILE @@FETCH_STATUS = 0
BEGIN
EXEC sp_change_users_login 'update_one', @username, @username
FETCH NEXT FROM fixusers
INTO @username
END CLOSE fixusers
DEALLOCATE fixusers
This code will work for SQL2008, but was written to be backward compatible for SQL2000.