If you get this warning in your apache logs, don't worry, it's perfectly normal.
[warn] RSA server certificate CommonName (CN) `localhost' does NOT match server name!?
[warn] Init: SSL server IP/port conflict: www.domain.com:443
[warn] Init: You should not use name-based virtual hosts in conjunction with SSL!!
Note that these are just warnings, not errors.