Massachusetts has very strict firearms storage laws. If you are the lawful owner of a firearm and it is not under your direct control, the firearm(s) must be secured so that it is "inoperable by any person other than the owner or other lawfully authorized user". That means that if you do not have the firearm within arms reach it should be "secured in a locked container or equipped with a tamper-resistant mechanical lock". NEVER leave a firearm unattended unless it is secured in an appropriate container or with an appropriate lock.
The laws for transporting a firearm differ. If you have an unrestricted LTC you may ONLY transport a loaded handgun under your direct control on a public way. If you do not have an unrestricted LTC or if you are transporting rifles or shotguns, all firearms (handguns, rifles and shotguns) MUST be unloaded and in a locked container. A locked trunk or rear storage area (out of reach by the driver and passengers) complies with this rule however, having the firearms in a locked container prevents misunderstandings that might occur in the event of a mechanical breakdown or traffic stop by a Law Enforcement Officer. Also, note that having the firearm only secured with tamper-resistant mechanical lock DOES NOT comply with the rule.