how highrise/famspam do custom emails

hey all,

i’m trying to implement a system that allows mail to be sent to a custom e-mail address, like how highrise allows you to forward mail to an account specific address. Anyone know how this is accomplished? My current solutino would be to have a mail daemon running that periodically polls a mail server using POP or IMAP, but I’m not sure how to check the many different addresses. Would those just be aliases to one actual address? Any insight would be appreciated