WASHINGTON, DC - JUNE 23:  FBI Director James Comey participates in a news conference on child sex trafficking, at FBI headquarters, June 23, 2014 in Washington, DC. Director Comey said that 168 juveniles have been recovered in a nationwide operation targeting commercial child sex trafficking.  (Photo by Mark Wilson/Getty Images)
Mark Wilson/Getty Images
WASHINGTON, DC - JUNE 23: FBI Director James Comey participates in a news conference on child sex trafficking, at FBI headquarters, June 23, 2014 in Washington, DC. Director Comey said that 168 juveniles have been recovered in a nationwide operation targeting commercial child sex trafficking. (Photo by Mark Wilson/Getty Images)
Now playing
01:05
Who is James Comey?
Getty Images
Now playing
01:12
Trump: I didn't fire Comey because of Russia
Ousted FBI director James Comey listens during a hearing before the Senate Select Committee on Intelligence on Capitol Hill June 8, 2017 in Washington, DC.
BRENDAN SMIALOWSKI/AFP/Getty Images
Ousted FBI director James Comey listens during a hearing before the Senate Select Committee on Intelligence on Capitol Hill June 8, 2017 in Washington, DC.
Now playing
01:20
Memos add new details to Comey's story
Conway Cuomo 04162018
CNN
Conway Cuomo 04162018
Now playing
01:48
Conway: All Comey had to do was keep mouth shut
Now playing
01:22
Toobin: Comey's account devastating for Trump
Rick Santorum
Rick Santorum
Now playing
01:29
Santorum rips Comey's 'tell-nothing' book
Team Coco
Now playing
03:50
Comey on Conan: Trump spy claims are made up
photo illustration: getty images/flatiron books/allie schmitz/cnn
Now playing
01:44
Trump unloads on Twitter at Comey
Now playing
04:46
Cooper questions Trump's respect for the law
Kellyanne Conway newday 04162018
CNN
Kellyanne Conway newday 04162018
Now playing
02:01
Conway: Comey's FBI was a hot mess
comey abc 2
ABC
comey abc 2
Now playing
02:49
Comey: Briefing Trump felt like out-of-body experience
WASHINGTON, DC - JUNE 08: Former FBI Director James Comey leaves a closed session with the Senate Intelligence Committee in the Hart Senate Office Building on Capitol Hill June 8, 2017 in Washington, DC. Comey said that President Donald Trump pressured him to drop the FBI's investigation into former National Security Advisor Michael Flynn and demanded Comey's loyalty during the one-on-one meetings he had with president. (Photo by Drew Angerer/Getty Images)
Drew Angerer/Getty Images
WASHINGTON, DC - JUNE 08: Former FBI Director James Comey leaves a closed session with the Senate Intelligence Committee in the Hart Senate Office Building on Capitol Hill June 8, 2017 in Washington, DC. Comey said that President Donald Trump pressured him to drop the FBI's investigation into former National Security Advisor Michael Flynn and demanded Comey's loyalty during the one-on-one meetings he had with president. (Photo by Drew Angerer/Getty Images)
Now playing
00:52
White House: Comey a 'disgraced partisan hack'
ABC
Now playing
02:04
Comey: Trump unfazed by Russian meddling
CNN
Now playing
01:20
Clapper: Comey accounts are accurate
CNN Illustration/Getty Images
Now playing
02:08
Comey details 2017 meeting with Trump in book
WASHINGTON, DC - JANUARY 22: U.S. President Donald Trump (L) shakes hands with James Comey, director of the Federal Bureau of Investigation (FBI), during an Inaugural Law Enforcement Officers and First Responders Reception in the Blue Room of the White House on January 22, 2017 in Washington, DC. Trump today mocked protesters who gathered for large demonstrations across the U.S. and the world on Saturday to signal discontent with his leadership, but later offered a more conciliatory tone, saying he recognized such marches as a "hallmark of our democracy." (Photo by Andrew Harrer-Pool/Getty Images)
Pool/Getty Images North America/Getty Images
WASHINGTON, DC - JANUARY 22: U.S. President Donald Trump (L) shakes hands with James Comey, director of the Federal Bureau of Investigation (FBI), during an Inaugural Law Enforcement Officers and First Responders Reception in the Blue Room of the White House on January 22, 2017 in Washington, DC. Trump today mocked protesters who gathered for large demonstrations across the U.S. and the world on Saturday to signal discontent with his leadership, but later offered a more conciliatory tone, saying he recognized such marches as a "hallmark of our democracy." (Photo by Andrew Harrer-Pool/Getty Images)
Now playing
02:21
Trump and Comey's ups and downs
Ousted FBI director James Comey listens during a hearing before the Senate Select Committee on Intelligence on Capitol Hill June 8, 2017 in Washington, DC.
BRENDAN SMIALOWSKI/AFP/Getty Images
Ousted FBI director James Comey listens during a hearing before the Senate Select Committee on Intelligence on Capitol Hill June 8, 2017 in Washington, DC.
Now playing
02:25
Timeline of Trump firing James Comey
Washington CNN —  

Then-President Barack Obama reassured then-FBI Director James Comey of his support after the 2016 election during a private meeting in the Oval Office, Comey writes in his upcoming book.

Comey recalls that during the meeting, in late November 2016, Obama told him, “I picked you to be FBI director because of your integrity and your ability. I want you to know that nothing – nothing – has happened in the last year to change my view.”

CNN obtained a copy of the book and corroborated news reports about Comey’s highly anticipated recounting of his time in the Trump administration.

Comey had been widely criticized for his handling of Hillary Clinton’s email server investigation when he announced just before the presidential election that the FBI was reopening the probe. In the days leading up the election, he announced there were no new developments, but Clinton has said Comey’s actions contributed to her loss.

“He, I think, forever changed history,” Clinton said about Comey in an interview about her memoir with CNN’s Anderson Cooper in September 2017.

Additionally, Comey writes in his book that his handling of the email probe could have been affected by the general assumption that Clinton would win the election.

“It is entirely possible,” Comey writes, that “my concern about making her an illegitimate president by concealing the restarted investigation bore greater weight than it would have if the election appeared closer or if Donald Trump were ahead in all polls. But I don’t know.”

Comey’s new book, titled “A Higher Loyalty,” is set to be released next week.

Trump allies are prepping an extensive campaign to undermine Comey’s credibility as he goes on his publicity tour, CNN reported Thursday.

The plan, obtained by CNN, calls for referring to Comey as “Lyin’ Comey” through a website, digital advertising and talking points to be sent to Republicans across the country. The White House signed off on the plan, which is being overseen by the Republican National Committee.

Comey served as the head of the FBI until Trump fired him in May 2017.

CNN’s Lauren del Valle, Eli Watkins and Jeff Zeleny contributed to this report.