Exceptions include drinking at a block party or “similar function for which a permit has been obtained” as well as premises licensed for the sale and consumption of alcohol. The punishment for violations is a fine of no more than $25 or imprisonment of up to five days, or both.

Paul J. Browne, the Police Department’s chief spokesman, said in statement about Mr. VanRy’s summons: “The officer observed a violation. The subject has a right to dispute it.”

Mr. VanRy will contest the summons at a court appearance in November by pleading not guilty. He questioned the notion that his stoop is considered a “public place” as defined by the law. Besides, he pointed out, Mayor Michael R. Bloomberg was photographed by The New York Post in May sipping a glass of wine at Brooklyn Bridge Park.

“It’s one of those laws that a lot of people know it’s there, but how heavily it should be enforced is a question,” Mr. VanRy said.

Steve Wasserman, a lawyer with the criminal practice of the Legal Aid Society, questioned the wording of the law, adding that legal arguments could be made that a stoop is not a place that a “substantial group of persons” can gain access to.

“This is an open question,” he said of the law. “There’s also a larger constitutional question, if a piece of your private property were being treated as if it were a public place. You couldn’t get arrested for drinking that beer in your kitchen. Now you’re sitting on your stoop. The stoop may be more like your kitchen than your sidewalk.”

Richard Briffault, a professor at Columbia University Law School and an expert in property and local government law, said Mr. VanRy’s summons illustrated the thin line between private and public property. “It’s quite possible to be on private property and in public at the same time,” he said.