-/example/etc/webdefault.xml中的更改
<security-constraint>
<web-resource-collection>
<web-resource-name>Solr authenticated application</web-resource-name>
<url-pattern>/</url-pattern>
</web-resource-collection>
<auth-constraint>
<role-name>core1-role</role-name>
</auth-constraint>
</security-constraint>
<login-config>
<auth-method>BASIC</auth-method>
<realm-name>Test Realm</realm-name>
</login-config>
也可以从/example/etc/jetty.xml修改jetty.xml文件
<Call name="addBean">
<Arg>
<New class="org.eclipse.jetty.security.HashLoginService">
<Set name="name">Test Realm</Set>
<Set name="config"><SystemProperty name="jetty.home" default="."/>/etc/realm.properties</Set>
<Set name="refreshInterval">0</Set>
</New>
</Arg>
</Call>
我已经按照solr中有关身份验证的建议进行了更改。出现一个对话框,在其中输入用户名和密码。即使输入正确的用户名和密码,也不会带我进入solr主屏幕。我在这里做错什么了吗?
我已经将绝对路径更改为相对路径
<SystemProperty name="jetty.home" default="."/>/etc/realm.properties</Set>
解决了我的问题!
本文收集自互联网,转载请注明来源。
如有侵权,请联系[email protected] 删除。
我来说两句