If you wanted simplify even more and save some typing, you could change both the owner and group with one command using the format:
[CODE]
chown username:groupname filename (assuming you’re already in the same directory as the desired file, otherwise use /path/to/file)
[/CODE]
That would make step 2:
[CODE]
chown www-data:www-data /var/www/fog/dban
[/CODE]
And step 4:
[CODE]
chown www-data:www-data /var/www/fog/dban/*
[/CODE]
Edit:
In your case specifically, I think you could actually combine steps 2 & 4 using:
[CODE]
sudo chown -R www-data:www-data /var/www/fog/dban
[/CODE]