Cas sec filter

can we make cas (and probably even ldap) an optional module? If it's not too hard