Probably not illegal if you agreed to their ToS.
(Even if Anthropic had an un-compromised model around, you'd have to let the researcher use it for an indefinite period in order to show that is capable of doing that research, which a court is unlikely to want to get involved in.)