ALBANY — The state comptroller’s office is working with law enforcement officials to investigate a pattern of stipends being doled out to state senators for committee positions they did not hold, according to a person with direct knowledge of the inquiry.

The person, who spoke on the condition of anonymity because of the sensitivity of the investigation, said that the law enforcement agency contacted the comptroller’s office but would not specify which entity had done so.

The investigation raised the stakes in a fast-moving scandal that has engulfed the State Capitol and the Senate majority leader, John J. Flanagan of Long Island. His Republican leadership approved the plan to award tens of thousands of dollars to certain Senate committee vice chairmen, even though they are not explicitly allowed stipends under state law.

Beginning in 2016, Mr. Flanagan ordered the secretary to the Senate to redirect stipends earmarked for some committee chairmen to those second in command. That order was recorded in payment documents sent by the Senate to the comptroller’s office, falsely identifying senators as chairmen of various committees — making them eligible for stipends, known here as lulus, of $12,500 to $18,000 a year. Mr. Flanagan and his legal team have argued that such payments were legal and constitutional, and that the documents were intended to ensure the correct payments for senators doing extra work in committees.