Parents used bear spray to fend off grizzly bear that attacked their 10-year-old son at Yellowstone National Park

The family had been hiking near the Old Faithful geyser when the bear attacked.

A family exploring Yellowstone National Park was able to save their 10-year-old son from a grizzly bear using bear spray they had rented from a kiosk nearby, according to reports.

Sally Vering, the founder of the Bear Aware kiosk at Yellowstone's Canyon Village, told ABC affiliate KTMF in Missoula, Montana, the family emailed her to thank her for selling them the spray.

Park-goers can rent the spray and watch a training video on how to use it at the store, according to KTMF. People tend to rent the spray rather than buy it to save money, Vering said.

"We are grateful for the bear spray and training which I am convinced saved at least one life on Thursday," the boy's father wrote, Vering said.

The family had been walking on a trail southeast of the famed Old Faithful geyser during a snowy day on Thursday when a grizzly bear knocked the boy to the ground and bit him in the back, park officials told KTMF.

Park rangers confirmed the attack to the local station.

After the family used the spray to save the boy's life, they returned it back to the rental store.

The family said the spray "worked immediately," employee Sarah Kosey told KTMF.

"They were just thankful that they had it with them at the time," Kosey said.

The seriousness of the boys' injuries from the attack is unclear. The family was heading home to Washington as of Monday night, according to KTMF.

"That family knew what to do," Vering said. "They saved their child’s life. They saved their own life. To be a part of that is astonishing."

Ohio resident Shane Burkholder watched the training video and rented a can of bear spray for his own family, he said.

"The affordability of having bear spray and bear spray training right here on park premises is invaluable," he told KTMF.

Bear spray is technically made of hot peppers and sprays up to 30 feet to burn the eyes and noses of the bear.

Vering said she decided to start the bear spray business four years ago. She realized how important it could be after two people died from a bear attack while hiking in Yellowstone in the summer of 2011 and after her own encounter with a bear at Yellowstone in 2009.

None of the three victims who died as a result of a bear attack in the last decade used bear spray, according to KTMF.