Benjamin Nathaniel Smith, the white supremacist identified by police as the drive-by gunman in last weekend's racially motivated shooting spree across two states, bought his guns late last month from an unlicensed dealer after failing a background check initiated by a licensed seller, state and federal authorities said today.

Smith's rampage ended Sunday night with the 21-year-old Indiana University student from Chicago's prosperous North Shore suburbs taking his own life with one of his guns as police tried to arrest him in the southern Illinois town of Salem.

Jerry Singer, a special agent for the federal Bureau of Alcohol, Tobacco and Firearms, said Smith bought a Bryco .380-caliber handgun from an illegal dealer in the Peoria area on June 26, three days after he tried to buy weapons from a licensed dealer in the same area.

Then on June 29--three days before the start of the three-day shooting rampage in Illinois and Indiana that left two men dead and nine others wounded--Smith bought a .22-caliber semiautomatic pistol from the same unlicensed dealer.

Authorities believe the .22-caliber pistol was used in a number of the multiple shootings linked to Smith, including the wounding of six Orthodox Jews walking home from Sabbath prayers in the Rogers Park area of Chicago on Friday night.

On the same night, Ricky Byrdsong, 43, a black former basketball coach at Northwestern University, was shot in the back and killed while walking with two of his children in the suburb of Skokie. On Sunday morning, Won Joon Yoon, 26, an Indiana University graduate student, was shot in the back and killed outside a Korean United Methodist Church in Bloomington, Ind.

In a previously scheduled speech in East St. Louis, Ill., President Clinton said tonight that Smith was "motivated by some blind racial hatred against anybody who didn't happen to be white."

Even as the United States stands up against ethnic hatred in Kosovo and elsewhere, he said, "We've still got work to do here at home. . . . We must search the hearts of our citizens and search the strength of our community. Congress should pass the hate crimes legislation, but we should rid our hearts of hatred, immediately."

Singer declined to identify the illegal dealer, who he said already had been under investigation before Smith made the purchases. He said the dealer's name has been forwarded to the U.S. attorney's office in Springfield, Ill.

Singer said Smith bought his guns from a street dealer. Such vendors are more prevalent than unlicensed dealers who operate at gun shows.

The issue of requiring unlicensed dealers at gun shows to initiate background checks on firearms sales has been contentious in Congress. The House last month defeated gun control legislation that included mandates for such checks after a battle between supporters of the National Rifle Association and gun control advocates. Under current law, unlicensed dealers at gun shows do not have to perform background checks, but licensed dealers, who account for a majority of gun show sales, must initiate checks that take up to three days. The House defeated the new legislation after Rep. John D. Dingell (D-Mich.) offered an amendment that weakened the control system by cutting the time to 24 hours.

Sgt. Michael Ruth, spokesman for the law enforcement task force from Illinois, Indiana and the FBI that is investigating the Smith case, said Smith had attempted to make a legal gun purchase on June 23 at a Peoria Heights gun shop but was turned down after a background check revealed that a former girlfriend of Smith obtained a court protection order two years ago after he allegedly beat her.

The owner of the Heights Gun and Hunter Supplies, Tony Schneider, said in a telephone interview that Smith tried to buy two 9mm handguns, a 12-gauge shotgun and ammunition. Schneider said he submitted the proposed sale for a background check on Smith, and the next day received a call from the Illinois State Police in Springfield rejecting Smith's purchase. Three days later, when Smith came to the store to collect his guns, Schneider told him of the rejection. The gun shop owner said Smith looked perplexed and noted that several weeks earlier the state police had issued him a firearm card authorizing him to make a gun purchase.

"It seemed a little bit strange to me, too. It had never happened before," Schneider said.

The firearm card, the initial step in a gun purchase, is usually issued after a preliminary background check. Smith was not agitated, Schneider said, but wondered how it could happen, saying he would "check it out." He then left the shop, the dealer said.

Lt. David Sanders of the Illinois State Police headquarters in Springfield said that after Smith applied for the firearm card on June 4, a check of records turned up the protective order obtained by the former girlfriend, Elizabeth Ann Sahr. She alleged that Smith beat her up in his dormitory room at Indiana University in Bloomington in October 1997.

Sanders said there were "discrepancies" between the gun card application and the protective order records, including a 25-pound weight difference and differences in middle initial and eye color.

"The person who reviewed the application determined that this wasn't a match," Sanders said. "They made a judgment call and allowed the application to go through because they couldn't say with certainty it was the same Smith."

Sanders called the first background check "an initial go-around--just a first- and last-name check." The more thorough background check made after Smith tried to buy three guns at Schneider's store confirmed that the court's protective order had been issued against Smith, resulting in an "automatic denial," Sanders said.

Meanwhile, police gathered evidence from the eight different law enforcement jurisdictions where the shootings occurred and sent them to the Illinois State Police crime laboratory in Maywood, a Chicago suburb. The evidence will be analyzed there to determine conclusively that the victims were shot with Smith's guns. Ruth said ballistics tests on shell casings and slugs probably will not be completed before the end of the week.

He said police armed with a warrant searched Smith's apartment in Morton, in downstate Illinois, last night and seized a receipt for ammunition, two boxes for guns, bundles of antisemitic literature and white supremacy pamphlets similar to those Smith distributed at the University of Illinois, Indiana University and around his former home in Wilmette, Ill.

"We believe Smith acted alone," Ruth said. "We're trying to piece together the circumstances that led to these acts, which would help us determine conclusively whether he acted alone."

Staff writer Charles Babington contributed to this report from East St. Louis, Ill.

CAPTION: Tony Schneider, a licensed dealer in Peoria Heights, Ill., wouldn't sell guns to Benjamin Nathaniel Smith.

CAPTION: Smith, above, failed a background check in effort to buy handguns because of a court protection order obtained two years ago by Elizabeth Sahr, left, a former girlfriend. Smith was alleged to have beaten her.