已采纳回答 / 慕少3361690 Realm中不是有密码么(老师的demo userMap存放用户密码 ),然后customRealm中的UsernamePasswordToken token = new UsernamePasswordToken("Mark", "123456");,这个123456密码与Map中密码比较,代码是通过SimpleAuthenticationInfo authenticationInfo = new SimpleAuthenticationInfo("Mark", password,"userReal...