S-JIS[2010-09-20] 変更履歴

GAE web.xml

Google App Engine(GAE)のwar/WEB-INF/web.xmlのメモ。


security-constraint

security-constraint要素によって、アクセス制限をかけることが出来る。

例:

<?xml version="1.0" encoding="utf-8"?>

<web-app xmlns="http://java.sun.com/xml/ns/javaee" version="2.5">
〜
	<security-constraint>
		<web-resource-collection>
			<url-pattern>/ccc/*</url-pattern>
		</web-resource-collection>
		<auth-constraint>
			<role-name>admin</role-name>
		</auth-constraint>
	</security-constraint>
</web-app>

「http://aaa.appspot.com/ccc/〜」にアクセスしようとすると、管理者でログインすることが求められる。
(Googleアカウントのログイン画面が表示される)


GAEへ戻る / 技術メモへ戻る
メールの送信先:ひしだま