NASA plans to land a crew on the moon by 2024 and then on Mars, possibly in the 30s.
Someday soon we will have colonies on Mars and permanent manned bases both there and on the Moon. Unlike short-term missions, the long-term foundations will need to be as self-sufficient as possible.
Much research has been done to prepare for an in situ resource use (ISRU) that could help build and sustain one lunar base.
Now, similar ideas for colonies on Mars are gaining ground with a new study, published on PNAS, which suggests a way to use the salt water frost found on Mars to get breathable air and fuel.
Living away from the Earth
It will be even more important to be able to pitch tents on Mars than on the Moon, because Mars is much further away, and transportation costs and times are much greater.
A major resource problem is how to provide enough oxygen for the crew, and the future inhabitants of the colonies on Mars, to breathe. Mars has only a thin atmosphere, with a surface pressure less than one hundredth of Earth's.
Even worse, there is 96% carbon dioxide with only 0,1% oxygen. The Earth's atmosphere is made up of 21% oxygen.

MOXIE takes care of it
NASA's Mars2020 rover, Perseverance, already en route to Mars, carries with it an experiment called MOXIE, an acronym that stands for Mars OXygen In situ Experiment.
The purpose of MOXIE is to demonstrate that oxygen can be produced from carbon dioxide in the atmosphere of Mars by using electricity to split it into a mixture of oxygen and carbon monoxide, through a process called electrolysis.
If it works as intended, oxygen can be collected and used to give colonies on Mars something to breathe or as a component of fuel.
Carbon monoxide? That just wouldn't help, and it would be reintroduced into the Martian atmosphere.
Oxygen from the Martian brine
A new way has emerged, however, which would consume 25 times less electricity to produce the same amount of oxygen.
In the new study, a team from Washington University in the United States demonstrates how electrolysis can be used efficiently to produce both oxygen and hydrogen from the "brine" found on the red planet.
The team found that when starting from a concentrated solution of magnesium perchlorate, it is relatively easy to split the aqueous component of the brine into oxygen and hydrogen using electrolysis.
Magnesium perchlorate is just what it looks like brackish water on Mars, as seen for example when droplets of liquid appeared on the legs of NASA's Phoenix lander, which landed in the far north of Mars in 2008 The Curiosity rover also found evidence of calcium perchlorate brine just south of the Martian equator.
Perchlorate salts are what prevents concentrated brines from freezing even at the low surface temperatures of Mars.
Practical options
It remains to be seen whether the use of this "brine" will indeed prove to be the most practical way of producing oxygen for colonies on Mars.
And while on the move?
Hydrogen from brine electrolysis could be used as rocket fuel, the study points out.
In fact, to do this, you need to use oxygen as a complementary component of the fuel. But at least this will offer two possible options: breathing oxygen or using it in a fuel mixture consisting of hydrogen plus oxygen.
There is another way to replenish oxygen, of course, which would be to grow plants in colonies on Mars. These could absorb the carbon dioxide exhaled by the crew and release oxygen through photosynthesis. Crew members could also eat some of the plants, which would be a welcome source of fresh food.