1. A method of matching a data packet to a rule in a network gateway having a rule base, comprising determining, by a network gateway, one or more identification values on the basis of the data packet, querying and receiving, by the network gateway, property values associated with said one or more identification values, said property values being coded into a bit sequence, wherein each bit of the sequence represents a value of a different property and indicates whether the respective property is set or not, comparing, by the network gateway, said -queried bit sequence to at least one rule in a rule base associated with the network gateway, said at least one rule comprising a bit sequence and an action, and taking the action defined in said at least one rule, if said bit sequence of the rule match the queried bit sequence corresponding property values associated with said one or more identification values.