The real estate listing that appeared briefly in Brooklyn last week sounded beguiling: two spacious, sun-drenched, full-floor apartments in a wide brick townhome in Fort Greene with spectacular outdoor spaces and period details.

The “wonderful vegan landlord,” the broker wrote, had only one house rule: “no meat/fish in the building.”

Even in a city where renters will pay mansionesque prices to live in an apartment with a bathtub in the kitchen or a studio so narrow you can touch both walls at once, the meatless walkup is unusual.

But at a by-appointment-only open house on Sunday, the steady stream of prospective tenants — only some of whom said they were vegetarians — indicated that the rule was not an automatic deal breaker. (Nor, apparently, was the price: The apartments, both one-bedrooms, are renting for $4,500 and $5,750.)

Actually, the broker, Andrea Kelly, explained to one prospect, meat eaters were not banned; cooking meat and fish was. “It’s not vegetarian-only, but the owner lives in the building and doesn’t want the smell of cooking meat drifting upstairs,” she said.

So, sushi, steak tartare and takeout: yes. Roasting a chicken: absolutely not.

The owner, Michal Arieh Lerer, refused to speak to a reporter, and Ms. Kelly and her employers at Douglas Elliman declined to comment. But Ms. Lerer’s ex-husband, who co-owns the building and is also vegan, said that they both had refused to rent to carnivores who cook since buying the house in 2007.

“It’s not about discrimination,” said the ex-husband, Motti Lerer. “You have to fit into the building.”

All of which raises the question: Is this legal?

It seems to be. The city’s Human Rights Law lists 14 characteristics that landlords are not allowed to consider in deciding whether to rent an apartment to someone, including age, race, family status, job, source of income and sexual orientation. Fondness for hamburgers is not one of them.

It is this “allowed unless specifically forbidden” construction of anti-discrimination law that makes it perfectly legal for landlords to refuse to rent to smokers — they are not a protected class either.

Lucas A. Ferrara, an adjunct professor at New York Law School and co-author of the multivolume book “Landlord and Tenant Practice in New York,” said a potential tenant might be able to fight the meat ban if, for example, they showed they had a medical condition that required some sort of “reasonable accommodation” on the landlord’s part.

“Absent an exception of that type,” Mr. Ferrara wrote, “the restriction would otherwise be permissible.”

The listing that mentioned the rule, on nextdoor.com, was taken down on Friday, the day after it was posted, but Douglas Elliman still lists the apartments on its own site, though without mention of the meat policy. The listings do note, “Cats welcome on a case-by-case basis (only one, please).”

One curious couple who did not know about the meat rule balked when they heard about it.

“Oh, we don’t fulfill those requirements,” said the woman, Tessa Ruben.

Then she and her partner, Darian Ghassemi, thought a little more.

“We order in a lot anyway,” said Ms. Ruben, 29, who works for a nonprofit.

“The terrace looks cool,” said Mr. Ghassemi, 31, who works in sales.

They were not able to get into the building because they didn’t have an appointment to view the apartments. After a little more discussion, they decided this was probably for the best.

“What makes me more nervous than the rule itself,” Ms. Ruben said, “is knowing there’s someone upstairs making sure you follow it.”