Directions for implementing CAS are contained in the file
/opt/webwork/webwork2/conf/authen_CAS.conf.dist
One correction though: there should be a semicolon at the end of the line
include("conf/authen_CAS.conf");
(If you want to implement CAS for some courses but not others, don't put the line include("conf/authen_CAS.conf"); in your localOverrides.conf file. Instead, put it in the course.conf file of each course that is to use CAS.)
There is also a moodle-WeBWorK bridge which allows single sign on from moodle into WeBWorK and exports the homework grades back to the moodle gradebook.