(CNN) -- Sen. John McCain vowed Wednesday to fight religious persecution, human trafficking, child pornography and other "evil" if he becomes president.
The speech at Oakland University in Rochester, Michigan, was part of the presumptive Republican presidential nominee's efforts to reach out to conservatives within his party.
The speech emphasized many issues social conservatives have championed.
McCain railed against "a tendency in our age to accede to the spurious excuse of moral relativism and turn away from the harshest examples of man's inhumanity to man, to ignore the darker side of human nature that encroaches upon our decency by subtle degree."
McCain singled out China, Iran, Myanmar, Sudan, North Korea and Saudi Arabia for restricting religious freedom and said he would make religious freedom "a subject of great importance" in his foreign policy if he became president.
McCain also said he would crack down on human trafficking by creating a inter-agency task force to strengthen cooperation between federal, state and local law enforcement.
McCain said he would to work to change the economic incentives underpinning trafficking as well as doing more to aid the victims of "this evil form of 21st-century slavery."
He hinted that he would try to end the practice of genital mutilation, saying "the United States are predicated on a shared respect for the basic right of women and children not to suffer atrocities to their physical and emotional health to protect traditions that should have been ended long ago."
The presidential nominee also said he would work to promote cooperation between federal and local officials to fight child pornography and online sexual predators.
Even though McCain wrapped up the GOP nomination after the Texas and Ohio primaries March 4, the primary results from North Carolina and Indiana show that some Republicans are not ready to line up behind the Arizona Republican.
Nearly one in four voters in the Republican primary in North Carolina voted for former presidential candidate Mike Huckabee or Rep. Ron Paul of Texas, or indicated no preference. Huckabee has endorsed McCain.
In Indiana, a similar percentage of Republican voters did not cast ballots for McCain. Instead, they voted for Huckabee, Paul or former presidential candidate Mitt Romney. Romney has also backed McCain.
McCain's speech comes a day after he pledged to nominate strict constructionist, conservative judges to the federal bench, presumably to gain support among conservatives.
"It will fall to the next president to nominate hundreds of qualified men and women to the federal courts, and the choices we make will reach far into the future," he said during a speech at Wake Forest University in North Carolina.
"My two prospective opponents and I have very different ideas about the nature and proper exercise of judicial power," he said of Democratic Sens. Hillary Clinton and Barack Obama.
"We would nominate judges of a different kind, a different caliber, a different understanding of judicial authority and its limits." Watch more of McCain's comments »
Many conservative members are suspicious of McCain on the issue of judges because of his involvement in 2006 in the Senate "gang of 14."
That bipartisan group of senators sought to reach a consensus on President Bush's judicial appointees, blocking some of the president's most conservative nominations while promising to confirm others.
The group formed after then-Senate Majority Leader Bill Frist threatened to remove the ability to filibuster judicial nominations after Democratic senators blocked a number of Bush nominees. Watch why McCain is reading out to conservatives »
But many conservatives responded positively to McCain's speech.
"[It was a] strong speech ... very encouraging. McCain has drawn a clear line between his support for judicial restraint and Obama's promise to appoint liberal judicial activists," said Ed Whelan, president of the Ethics and Public Policy Center and a former law clerk for Supreme Court Justice Antonin Scalia.