ASF matcher (not optimal implementation)