Libertarian presidential hopeful Gary Johnson, possibly benefitting from dissatisfaction with the two major parties’ front-runners, is in double digits in a potential three-way race, according to a poll released Thursday.

In a three-way contest, Democratic front-runner Hillary Clinton was at 42 percent, GOP front-runner Donald Trump was at 34 percent, and Mr. Johnson, who is seeking the Libertarian Party’s nomination, was at 11 percent, according to the Monmouth University poll.

More than three-quarters of respondents didn’t know enough about Mr. Johnson, the former New Mexico governor and 2012 presidential candidate, to have formed an opinion. Mr. Johnson received more than 1 million votes in 2012 — a record for a Libertarian candidate — which amounted to about 1 percent of the popular vote.

But 40 percent of registered voters said they had a favorable opinion of Mrs. Clinton, compared to 51 percent with an unfavorable one.

Mr. Trump fared even worse, with 30 percent reporting a favorable opinion of him and 60 percent viewing him unfavorably.

“A vigorous third party campaign is a very real possibility this year, but it is not yet clear what the impact could be,” said Patrick Murray, director of the independent Monmouth University Polling Institute. “Including Johnson’s name in our polling seems to be more of a placeholder for voters who are not particularly thrilled with either major party choice right now.”

In a head-to-head match-up, Mrs. Clinton had a 10-point lead over Mr. Trump, 48 percent to 38 percent.