Posse comitatus is part of Britsh Common Law. The U.S. as well as Indian laws are based on British Common Law and include posse comitatus. Posse comitatus also gives police powers of arrest to the citizens.
Posse comitatus is embedded in Sections 37 to 39, 43, 46, 47, 52 and 60 in Chapter V Arrest Of Persons of the Criminal Procedure Code, Section 129(2) in Chapter X Maintenance of Public Order and Tranquility of the Criminal Procedure Code and Sections 96 to 106 Indian Penal Code flowing from Articles 21 as citizen's militia in personal capacity and control.
Fundamental rights and fundamental duties are two sides of the same coin and since fundamental right to assemble peaceably and with arms and citizen's militia in personal capacity and control is embedded and exists for citizens under Article 19(1)(b), that is why there exists corresponding reflection of fundamental duty of citizen's militia in personal capacity and control, under Articles 51A(b)(c),(d) & (i) and it also gets manifested under the Punjab Village and Small Towns Patrol Act, 1918 and the Himachal Pradesh Village And Small Towns Patrol Act, 1964. Under these acts, in order to do patrolling, able-bodied male inhabitants exercise two fundamental rights, right to assemble (peaceably as well as violently if situation compels) and the natural human right to keep and bear arms for patrolling. Similarly the natural human right to keep and bear arms, police powers and posse comitatus are also embedded in Civil Defense Act 1968.