To access the contents of a .dmg password protected file you received, just double-click its icon, enter the password and the content of the file will show up as a volume on your desktop. After working with it, eject the volume by clicking the Eject button in the sidebar of a Finder window or dragging its icon to the Trash. This kind of files can be natively accessed only on Mac OS X computers.