Session No 14
- 格式:doc
- 大小:102.00 KB
- 文档页数:28
hibernate深度学习游离状态HQL当我学完这个之后我仿佛都懂了 = =或许这就是 hibernate的⼒量吧.操纵持久化对象(Session)1.1. 在hibernate中java对象的状态Hibernate 把对象分为 4 种状态:¨ 持久化状态,¨ 临时状态,¨ 游离状态,¨ 删除状态.Session 的特定⽅法能使对象从⼀个状态转换到另⼀个状态1.2. 临时对象(transient)¨ 在使⽤代理主键的情况下, OID 通常为 null¨ 不处于 Session 的缓存中¨ 在数据库中没有对应的记录1.2.1. 删除对象(Removed)¨ OID 不为 null¨ 从⼀个 Session实例的缓存中删除¨ Session 已经计划将其从数据库删除, Session 在清理缓存时, 会执⾏ SQL delete 语句, 删除数据库中的对应记录¨ ⼀般情况下, 应⽤程序不该再使⽤被删除的对象1.2.2. 持久化对象(也叫”托管”)(Persist)1.2.3.¨ OID 不为 null¨ 位于 Session 缓存中¨ 持久化对象和数据库中的相关记录对应¨ Session 在清理缓存时, 会根据持久化对象的属性变化, 来同步更新数据库¨ 在同⼀个 Session 实例的缓存中, 数据库表中的每条记录只对应唯⼀的持久化对象1.2.4. 游离对象(也叫”脱管”)(Detached)¨ OID 不为 null¨ 不再处于 Session 的缓存中¨ ⼀般情况需下, 游离对象是由持久化对象转变过来的, 因此在数据库中可能还存在与它对应的记录1.2.5. 对象的状态转换说明(图)对象的状态转换图测试hibernate中java对象的状态程序代码⽣命周期状态tx = session.beginTransaction();开始⽣命周期临时状态Customer c = new Customer);Session.save(c)处于⽣命周期中转变为持久化状态Long id=c.getId();处于⽣命周期中处于持久化状态c = null;Customer c2 =(Customer)session.load(Customer.class,id);mit();session.close();处于⽣命周期中转变为游离态c2.getName();处于⽣命周期中处于游离态c2 = null;结束⽣命周期结束⽣命周期1.2.6. 对象的状态总结Session缓存存在对应的记录数据中存在对应的记录临时态no no持久态yes可能有也可能没有游离态no可能有(数据没有删除)也可能没有1.2.7. 操纵持久化对象的⽅法(Session中)1.2.8. save()Session 的 save() ⽅法使⼀个临时对象转变为持久化对象。
"maximum number of sessions reached"通常表示你的系统已经达到了它允许的最大会话数。
在大多数Linux系统中,这个限制是由`ulimit`命令设置的。
如果你想更改这个限制,你可以使用`ulimit`命令。
首先,你需要以root用户身份登录。
然后,你可以运行以下命令来更改最大会话数:
```bash
ulimit -u <新的最大会话数>
```
这里的`<新的最大会话数>`应该被替换为你希望设置的新限制。
例如,如果你想将最大会话数设置为2000,你应该运行:
```bash
ulimit -u 2000
```
这将会在你的当前会话中更改限制。
如果你希望永久更改这个限制,你需要将这个命令添加到
`/etc/security/limits.conf`文件中。
这可以通过以下命令完成:
```bash
echo "soft nofile <新的最大会话数>" >> /etc/security/limits.conf
echo "hard nofile <新的最大会话数>" >> /etc/security/limits.conf
```
请注意,对于一些系统,最大会话数可能会受到系统资源的限制,例如文件描述符的数量。
在这种情况下,你可能需要增加其他限制,如`nofile`,以允许更多的会话。
Thereisnosessionwithidsession多⼈使⽤⼀个账号1.问题场景:在dev和test环境开发时候,分配的账号是多⼈共⽤的,当⼀个⼈修改权限后,调⽤shiro的清楚服务器sesionId后,当其他⼈再次修改权限信息时候,由于服务器的sessionId已经被全部清空,就会报 There is no session with id "XXX"的问题2.解决⽅式:⽹上说的⼀般是由于SESSIONID和⽐如tomcat/jetty等使⽤的sessionId同名导致的,这个是⼀个原因。
不过我的原因是由于服务器所有的sessionId被清空了导致的,所以做了限制:当⼀个⽤户登录时候,我会先清空这个账号的所有缓存信息,这样不会导致⼀个账号在多个地⽅登录。
不过有些简单package mon.shiro.realm;import mon.collect.Maps;import com.sq.transportmanage.gateway.dao.entity.driverspark.CarAdmUser;import com.sq.transportmanage.gateway.dao.entity.driverspark.SaasPermission;import com.sq.transportmanage.gateway.dao.mapper.driverspark.ex.SaasPermissionExMapper;import com.sq.transportmanage.gateway.dao.mapper.driverspark.ex.SaasRoleExMapper;import com.sq.transportmanage.gateway.service.auth.MyDataSourceService;import mon.constants.Constants;import mon.constants.SaasConst;import mon.dto.SaasPermissionDTO;import mon.shiro.session.RedisSessionDAO;import com.sq.transportmanage.gateway.service.util.BeanUtil;import com.sq.transportmanage.gateway.service.util.MD5Utils;import org.apache.shiro.SecurityUtils;import org.apache.shiro.authc.*;import org.apache.shiro.authz.AuthorizationInfo;import org.apache.shiro.authz.SimpleAuthorizationInfo;import org.apache.shiro.realm.AuthorizingRealm;import org.apache.shiro.session.Session;import org.apache.shiro.subject.PrincipalCollection;import org.apache.shiro.subject.SimplePrincipalCollection;import org.apache.shiro.subject.support.DefaultSubjectContext;import org.apache.shiro.web.mgt.DefaultWebSecurityManager;import org.apache.shiro.web.session.mgt.DefaultWebSessionManager;import org.slf4j.Logger;import org.slf4j.LoggerFactory;import org.springframework.beans.factory.annotation.Autowired;import org.springframework.beans.factory.annotation.Qualifier;import ponent;import org.springframework.util.CollectionUtils;import java.security.NoSuchAlgorithmException;import java.util.*;/**认证与权限 **//*** 这个就是shiro SSOLogin 的⽤户获取的属性配置*/@Componentpublic class UsernamePasswordRealm extends AuthorizingRealm {private static final Logger logger = LoggerFactory.getLogger(UsernamePasswordRealm.class);@Autowiredprivate MyDataSourceService myDataSourceService;@Autowiredprivate SaasPermissionExMapper saasPermissionExMapper;@Autowiredprivate SaasRoleExMapper saasRoleExMapper;@Autowired@Qualifier("sessionDAO")private RedisSessionDAO redisSessionDAO;/**重写:获取⽤户的⾝份认证信息**/@Overrideprotected AuthenticationInfo doGetAuthenticationInfo(AuthenticationToken authenticationToken) throws AuthenticationException{( "[获取⽤户的⾝份认证信息开始]authenticationToken="+authenticationToken);try {UsernamePasswordToken token = (UsernamePasswordToken)authenticationToken;CarAdmUser adMUser = myDataSourceService.queryByAccount(token.getUsername());//处理session 防⽌⼀个账号多处登录try {redisSessionDAO.clearRelativeSession(null,null,adMUser.getUserId());} catch (Exception e) {("=========清除session异常============");}SSOLoginUser loginUser = new SSOLoginUser();loginUser.setId( adMUser.getUserId() );loginUser.setLoginName( adMUser.getAccount() );loginUser.setMobile( adMUser.getPhone() );loginUser.setName( adMUser.getUserName() );loginUser.setEmail(adMUser.getEmail());loginUser.setType(null); //loginUser.setStatus( adMUser.getStatus() );loginUser.setAccountType( adMUser.getAccountType() );loginUser.setLevel(adMUser.getLevel());loginUser.setMerchantId(adMUser.getMerchantId());loginUser.setSupplierIds(adMUser.getSuppliers());String md5= null;try {md5 = MD5Utils.getMD5DigestBase64(loginUser.getMerchantId().toString());} catch (NoSuchAlgorithmException e) {("sign error" + e);}if(Constants.MANAGE_MD5.equals(md5)){loginUser.setSuper(true);}else {loginUser.setSuper(false);}List<String> menuUrlList = saasPermissionExMapper.queryPermissionMenussOfUser(adMUser.getUserId());loginUser.setMenuUrlList(menuUrlList);/**当前⽤户所拥有的菜单权限**/List<Integer> permissionIds = saasPermissionExMapper.queryPermissionIdsOfUser(adMUser.getUserId());List<Byte> permissionTypes = Arrays.asList( new Byte[] { SaasConst.PermissionType.MENU });Map<Integer,List<SaasPermissionDTO>> mapPermission = Maps.newHashMap();/**查询所有的⼀级菜单**/if(!CollectionUtils.isEmpty(permissionIds)){List<SaasPermission> permissionList = saasPermissionExMapper.queryModularPermissions(permissionIds);Map<Integer,String> map = Maps.newHashMap();permissionList.forEach(list ->{map.put(list.getPermissionId(),list.getPermissionName());//查询所有⼀级菜单下的⼦菜单以树形结果返回List<SaasPermissionDTO> menuPerms = this.getChildren( permissionIds , list.getPermissionId(), permissionTypes);mapPermission.put(list.getPermissionId(),menuPerms);});loginUser.setMenuPermissionMap(map);loginUser.setMapPermission(mapPermission);}////---------------------------------------------------------------------------------------------------------数据权限BEGIN( "[获取⽤户的⾝份认证信息]="+loginUser);return new SimpleAuthenticationInfo(loginUser, authenticationToken.getCredentials() , this.getName() );} catch (Exception e) {logger.error("获取⽤户的⾝份认证信息异常",e);return null;}}/*** 查询每个⼀级菜单下的⼦菜单* @param permissionIds* @param parentPermissionId* @param permissionTypes tree 树形,list 列表* @return*/private List<SaasPermissionDTO> getChildren( List<Integer> permissionIds, Integer parentPermissionId, List<Byte> permissionTypes ){List<SaasPermission> childrenPos = saasPermissionExMapper.queryPermissions(permissionIds, parentPermissionId, null, permissionTypes, null, null);if(childrenPos==null || childrenPos.size()==0) {return null;}//递归List<SaasPermissionDTO> childrenDtos = BeanUtil.copyList(childrenPos, SaasPermissionDTO.class);Iterator<SaasPermissionDTO> iterator = childrenDtos.iterator();while (iterator.hasNext()) {SaasPermissionDTO childrenDto = iterator.next();List<SaasPermissionDTO> childs = this.getChildren( permissionIds, childrenDto.getPermissionId() , permissionTypes );childrenDto.setChildPermissions(childs);}return childrenDtos;}/*** 查询⾓⾊登录进来所拥有的菜单时候shiro实现* @param principalCollection* @return*/@Overrideprotected AuthorizationInfo doGetAuthorizationInfo(PrincipalCollection principalCollection) {SSOLoginUser loginUser = (SSOLoginUser) principalCollection.getPrimaryPrincipal();String account = loginUser.getLoginName(); //登录名List<String> perms_string = saasPermissionExMapper.queryPermissionCodesOfUser( loginUser.getId() ); List<String> roles_string = saasRoleExMapper.queryRoleCodesOfUser( loginUser.getId() );SimpleAuthorizationInfo authorizationInfo = new SimpleAuthorizationInfo();Set<String> roles = new HashSet<String>( roles_string );authorizationInfo.setRoles( roles );( "[获取⽤户授权信息(⾓⾊)] "+account+"="+roles);Set<String> perms = new HashSet<String>( perms_string );authorizationInfo.setStringPermissions(perms);( "[获取⽤户授权信息(权限)] "+account+"="+perms);return authorizationInfo;}@Overridepublic Object getAuthorizationCacheKey(PrincipalCollection principals) {SSOLoginUser loginUser = (SSOLoginUser) principals.getPrimaryPrincipal();String account = loginUser.getLoginName(); //登录名return"-AuthInfo-"+account;}@Overridepublic void clearCachedAuthorizationInfo(PrincipalCollection principals) {super.clearCachedAuthorizationInfo(principals);}@Overridepublic void clearCachedAuthenticationInfo(PrincipalCollection principals) {super.clearCachedAuthenticationInfo(principals);}@Overridepublic void clearCache(PrincipalCollection principals) {super.clearCache(principals);}}/**⼆、当权限信息、⾓⾊信息、⽤户信息发⽣变化时,同时清理与之相关联的会话**/@MyDataSource(value = DataSourceType.DRIVERSPARK_MASTER)public void clearRelativeSession( final Integer permissionId, final Integer roleId, final Integer userId ) {final Cache<Serializable, Session> cache = super.getActiveSessionsCache();//final Cache<Serializable, Session> cache = activeSessions;new Thread(new Runnable() {@SuppressWarnings("unchecked")@Overridepublic void run() {try{//A:如果当权限发⽣变化时,查询所关联的全部⾓⾊IDList<Integer> roleIds = new ArrayList<Integer>();if( permissionId!=null ) {roleIds = myDataSourceService.queryRoleIdsOfPermission( permissionId );}//B:如果当⾓⾊发⽣变化时,查询所关联的⽤户IDif( roleId !=null ) {roleIds.add(roleId);}List<Integer> userIds = new ArrayList<Integer>();if( roleIds.size()>0 ) {userIds = myDataSourceService.queryUserIdsOfRole( roleIds );}//C:如果当⽤户发⽣变化时,查询出这些⽤户的登录账户名称if( userId != null ) {("当⽤户发⽣变化时清除缓存userId={}",userId);userIds.add(userId);}List<String> accounts = new ArrayList<String>();if(userIds.size()>0) {accounts = myDataSourceService.queryAccountsOfUsers(userIds);}//D:汇总需要清理的REDIS KEY 和 sessionIdif(accounts.size() ==0) {return;}Set<String> redisKeysNeedDelete = new HashSet<String>();//这是需要清除的所有REDIS KEYSet<String> allSessionIds = new HashSet<String>();//这是需要清除的所有的sessionIdfor( String account : accounts) {redisKeysNeedDelete.add( KEY_PREFIX_OF_SESSIONID + account );Set<String> sessionIds = (Set<String>) redisTemplate.opsForValue().get(KEY_PREFIX_OF_SESSIONID+account);if(sessionIds!=null && sessionIds.size()>0) {allSessionIds.addAll(sessionIds);}}//E1:执⾏清除执久化的会话(这⾥是保存在REDIS中的)for( String sessionId : allSessionIds) {("执⾏清除REDIS的会话缓存sessionId={}",sessionId);redisKeysNeedDelete.add( KEY_PREFIX_OF_SESSION + sessionId );}redisTemplate.delete(redisKeysNeedDelete);//E2:执⾏清理shiro会话缓存if(cache!=null) {for(String sessionId : allSessionIds ){SimpleSession session = (SimpleSession)cache.get(sessionId);if(session!=null) {session.setExpired(true);}("执⾏清理shiro会话缓存sessionId={}",sessionId);cache.remove(sessionId);}}//E3:执⾏清理shiro 认证与授权缓存for( String account : accounts) {("执⾏清理shiro 认证与授权缓存account={}",account);//todo 此处不合理,应该⽤下⾯的代码这个是临时⽅案:执⾏退出的操作相当于⼿动点击退出这个触发条件太⼴泛了要加很多逻辑判断那些⼈需要退出/*Subject subject = SecurityUtils.getSubject();if(subject.isAuthenticated()) {subject.logout();}*/SSOLoginUser principal = new SSOLoginUser();principal.setLoginName( account );SimplePrincipalCollection simplePrincipalCollection = new SimplePrincipalCollection( );simplePrincipalCollection.add(principal, authorizingRealm.getName() );((UsernamePasswordRealm)authorizingRealm).clearCache( simplePrincipalCollection );}}catch(Exception ex) {logger.error("清除缓存异常",ex);}finally {//DynamicRoutingDataSource.setDefault("mdbcarmanage-DataSource");}}}).start();}。
session测试的测试点session测试的测试点1.session的创建时间点是打开浏览器访问开始创建session?还是⽤户登陆时开始创建session? 还是其它情况下创建的2.session的删除时间点过期⽂件是否删除,关闭浏览器时,session是否会删除?当有多个窗⼝时,是全部关掉还是关掉⼀个会删除session?3.session超时基于Session原理,需要验证系统session是否有超时机制,还需要验证session超时后功能是否还能继续⾛下去测试⽅法:1)打开⼀个页⾯,等着10分钟session超时时间到了,然后对页⾯进⾏操作,查看效果。
2)多TAB浏览器,在两个TAB页中都保留的是⽤户A的session记录,然后在其中⼀个TAB页执⾏退出操作,马上在另外⼀个页⾯进⾏要验证的操作,查看是能继续到下⼀步还是到登录页⾯。
4.session互窜即是⽤户A的操作被⽤户B执⾏:测试⽅法:多TAB浏览器,在两个TAB页中都保留的是⽤户A的session记录,然后在其中⼀个TAB页执⾏退出操作,登陆⽤户B,此时两个TAB页都是B的session,然后在另⼀个A的页⾯执⾏操作,查看是否能成功。
预期结果:有权限控制的操作,B不能执⾏A页⾯的操作,应该报错,没有权限控制的操作,B执⾏了A页⾯操作后,数据记录是B的⽽不是A的5.Session垃圾回收6.关闭浏览器同时关闭session7.Session 销毁8.session丢失代码问题9.不同浏览器Session的共享机制不⼀致IE中,所有打开的IE窗⼝(IE 进程)共享⼀个session。
除⾮,⽤户通过菜单 File > New session 打开新窗⼝,或者使⽤命令⾏参数iexplore.exe -nomerge 来打开IE。
另外,当所有IE窗⼝被关闭后,session 结束。
10.服务器端是否设置了最⼤并发session数量防⽌由于登录⼈数过多,造成服务器内存被消耗殆尽或服务器⽆响应的情况。
wlan ssid-profile "default"wpa-passphrase 1234567890 ---tkip设置provision-ap copy-provisioning-params ip-addr 192.168.102.250 provision-ap no ipaddrprovision-ap a-ant-gain 2provision-ap g-ant-gain 2provision-ap a-antenna 1provision-ap g-antenna 1provision-ap external-antennaprovision-ap master 192.168.102.100provision-ap server-ip 192.168.102.100provision-ap ap-group "default"provision-ap ap-name "00:0b:86:cb:bd:62"provision-ap no syslocationprovision-ap fqln ""provision-ap reprovision ip-addr 192.168.102.250interface loopback ip address "192.168.30.200"apboot> helpboot - run bootcmd or boot AP image or elf file or from flashcd - cfg register displaycw - cfg register writedis - disassemble instructionsdhcp - invoke DHCP client to obtain IP/boot paramseloop - loopback received ethernet framesflash - FLASH sub-systemgo - start application at address 'addr'help - print online helpmc - memory copymd - memory displaymii - MII sub-systemmtest - simple RAM testnetstat - net statisticsmw - memory writeping - ping net hostprintenv - env displaypurgeenv - purge envregs - display various regsreset - reset processorrun - run commands in an environment variablesaveenv - save environment variables to persistent storagesetenv - set variable in env (ipaddr/netmask/gatewayip/master/serverip) setenv ipaddr x.x.x.xsetenv netmask x.x.x.xsetenv gatewayip x.x.x.xsetenv serverip x.x.x.xsetenv master x.x.x.xtcpdump - dump received packetstcpsend - send TCP packettftpboot - boot via tftptlb - dump TLBtrace - dump trace bufferversion - print monitor versionwdog - stop refreshing watchdog timerapboot>No spanning-tree 关闭spanning-treeAdp discover disable 关闭ADPAdp imgp-join disable 关闭im-j一、WEB页面认证1、wlan ssid-profile (staff-ssid-profile) :定义ssid配置文件1.1 essid staff :定义ssid下的essid—显示出来的ssid2、wlan virtual-ap (staff-vap-profile) :定义virtual-ap的配置文件2.1 ssid-profile (staff-ssid-profile) :在virtual-ap下引用定义过SSID2.2 vlan ID aa,bb :把virtual-ap加入到要ssid所属VLAN3、aaa profile staff-aaa-profile :定义AAA认证配置文件4、aaa server-group (staff-servergroup) :定义server-group配置文件4.1 auth-server internal :定义认证服务器为本地认证4.2 set role condition role value-of 设置角色set role condition <condition> set-value <role> position <number>5、aaa authentication captive-portal (staff-auth-profile) :captive-portal配置5.1 server-group staff-servergroup :在下面引用定义过的server-group6、user-role staff-logon :定义用户登陆前权限的配文件6.1 access-list session logon-control position 1定义用户登陆前的权限--位置16.2 access-list session captiveportal position 2 定义用户登陆前的权限--26.3 Captive-Portal staff-auth-profile position 3定义过captive-portalRe-authentication interval 480 再次认证间隔480秒默认3600秒7、user-role vip-role :定义用户成功登陆后的配置文件7.1session-acl allowall 赋予所有允许权限session-acl http-acl 只有http8、wlan virtual-ap staff-vap-profile :进入定义过的virtual-ap配置文件8.1 aaa-profile staff-aaa-profile :引用定义过的AAA配置文件9、ap-group default :定义ap-group,最好用默认的9.1 virtual-ap staff-vap-profile :引用定义过的Virtual-ap配置文件10、aaa profile staff-aaa-profile :进入定义过的AAA配置文件10.1 initial-role staff-logon :把initial-role改为定义过用户登陆前配置11、aaa authentication-server internal use-local-switch :定义认证SERVER为本地交换机12、local-userdb add username staff password 123456 role vip-role :定义用户的登陆的用户名和密码及权限二、MAC 地址认证配置1、wlan ssid-profile (staff-ssid-profile) :定义ssid配置文件1.1 essid staff :定义ssid下的essid2、wlan virtual-ap (staff-vap-profile) :定义virtual-ap的配置文件2.1 ssid-profile (staff-ssid-profile) :virtual-ap下引用定义过的SSID配置文件2.2 vlan ID :把virtual-ap加入到要ssid所属的VLAN3、aaa profile staff-aaa-mac-profile :定义AAA认证配置文件4、aaa authentication mac staff-mac-profile :定义mac配置文件4.1 Delimiter dash :定义mac地址的格式4.2 Case upper (upper/lower):定义mac地址的大/小写备注:aaa authentication mac staff-mac-profileclone <profile>delimiter {colon|dash|none}max-authentication-failures 数字aaa authentication mac mac-blacklist MAC黑名单max-authentication-failures 5 最多认证失败次数5、aaa server-group (staff-macservergroup) :定义server-group配置文件5.1 auth-server internal :定义认证服务器为本地认证5.2 set role condition role value-of6、user-role staff-logon :定义用户登陆前权限的配文件6.1 access-list session logon-control :定义用户登陆前的权限6.2 access-list session captiveportal :定义用户登陆前的权限7、user-role vip-role :定义用户成功登陆后的配置文件7.1session-acl allowall :赋予权限8、wlan virtual-ap staff-vap-profile :进入定义过的virtual-ap配置文件8.1 aaa-profile staff-aaa-mac-profile :引用定义过的AAA配置文件9、ap-group default :定义ap-group,最好用默认的9.1 virtual-ap staff-vap-profile :引用定义过的Virtual-ap配置文件10、aaa profile staff-aaa-mac-profile :进入定义过的AAA配置文件10.1 initial-role staff-logon :把initial-role改为定义过的用户登陆前的配置文件10.2 authentication-mac staff-mac-profile :把定义的authentication mac文件引用10.3 mac-server-group staff-macservergroup :把定义的servergroup加入11、aaa authentication-server internal use-local-switch :定义认证SERVER为本地交换机12、local-userdb add username mac地址password mac地址 role vip-role :定义用户的登陆的用户名和密码及权限注意:如果是有线直接连在端口上的话要进行认证必须把连接口设为UNTRUSTED.同时在设定:进入aaa authentication wired 后设定:profile (staff-aaa-profile) 为你设定认证的AAA profileBlacklist:5次错误就拒绝访问show aaa authentication captive-portal default:Max authentication failures 改为5次show aaa authentication dot1x default:Max authentication failures 改为5次1、aaa bandwidth-contract "256" kbits "256"2、aaa bandwidth-contract "256" kbits 256ip access-list session "pass"any any any permit queue low!user-role "ap512"access-list "pass" position 1bw-contract "256" per-user upstreambw-contract "256" per-user downstreamaaa bandwidth-contract "2M-BW" mbits "2" 带宽2M控制aaa bandwidth-contract 128_up kbits 128 带宽128k控制aaa bandwidth-contract 512 kbits 512aaa bandwidth-contract 64 kbits 64aaa bandwidth-contract 256 kbits 256aaa bandwidth-contract 1 mbits 1 带宽1M控制aaa bandwidth-contract 128_up kbits 128user-role 128bw-contract 128_up per-user upstreamuser-role ap-rolesession-acl controlsession-acl ap-acl!user-role pre-employeesession-acl allowallMaster mobility controller configuration1Initial setup of Aruba-master2Core VLAN configuration and IP addressing3Core VLAN port assignment4Loopback IP address ----- interface loopback ip address 设置环回地址Deploy APs5配置AP VLAN6配置 AP VLAN DHCP Server7Connect Aruba APs8Provisioning Aruba APs(Aruba-master) (config-if)#write mSaving Configuration...ip dhcp pool "userpool" 定义pool的名字default-router 192.168.11.254 定义默认路由网关—loopback地址dns-server 192.168.11.254---202.106.0.20 定义DNS网关lease 8 0 0network 192.168.11.0 255.255.255.0service dhcp 启动dhcpinterface gigabitethernet 1/1no muxportswitchport mode trunkip default-gateway 192.168.0.254interface vlan 1no ip addressno ip igmpinterface gigabitethernet 1/1no switchport access vlaninterface loopback ip address "192.168.0.100"(Aruba800-4) (config) # show ip interface briefInterface IP Address / IP Netmask Admin Protocolvlan 1 172.16.0.254 / 255.255.255.0 up upvlan 10 192.168.0.1 / 255.255.255.0 up upvlan 30 192.168.30.200 / 255.255.255.0 up uploopback unassigned / unassigned up up(Aruba800-4) (config) # rf arm-profile default ----------关闭ARM后调整channel---ok (Aruba800-4) (Adaptive Radio Management (ARM) profile "default") #assignment disable (Aruba800-4) (Adaptive Radio Management (ARM) profile "default") #no scan(Aruba800-4) (Adaptive Radio Management (ARM) profile "default") #write memoryrf dot11g-radio-profile "default"tx-power 20 ------------------------发射功率调整rf dot11g-radio-profile "default"channel 11 ------------------------调整AP信道interface vlan 20ip address 192.168.0.1 255.255.255.0ip nat insideno ip igmp存配置:24 (Aruba2400) #configure t25(Aruba2400) (config) #copy tftp: 172.16.0.100 aruba2400-0904.cfg flash: 2400.bak 26(Aruba2400) (config) #copy flash: 2400.bak flash: 2400.cfg27(Aruba2400) # copy running-config tftp: 192.168.4.100 aruba2400-0904.cfgRadius配置:aaa authentication-server radius Radius1host <ipaddr>key <key>enableaaa server-group corpnetauth-server Radius1dot1x配置:aaa authentication dot1x corpnetaaa profile corpnetauthentication-dot1x corpnetdot1x-default-role employeedot1x-server-group corpnetvirtual AP:wlan ssid-profile corpnetessid Corpnetopmode wpa2-aeswlan virtual-ap corpnetvlan 1aaa-profile corpnetssid-profile corpnetap-group defaultvirtual-ap corpnet时间设定:time-range workhours periodic周期weekday 09:00 to 17:00ip access-list session restricted 受限制any any svc-http permit time-range workhoursany any svc-https permit time-range workhoursuser-role guestsession-acl restrictedmesh设置:ap mesh-radio-profile <profile-name>11a-portal-channel <11a-portal-channel>11g-portal-channel <11g-portal-channel>a-tx-rates [6|9|12|18|24|36|48|54]beacon-period <beacon-period>children <children>clone <source-profile-name>g-tx-rates [1|2|5|6|9|11|12|18|24|36|48|54]heartbeat-threshold <count>hop-count <hop-count>link-threshold <count>max-retries <max-retries>metric-algorithm {best-link-rssi|distributed-tree-rssimpv <vlan-id>rts-threshold <rts-threshold>tx-power <tx-power>ap mesh-radio-profile <profile-name>clone <source-profile-name>ap-group <group>mesh-radio-profile <profile-name>ap-name <name>mesh-radio-profile <profile-name>wlan ssid-profile <profile>essid <name>opmode <method> 方式wpa-passphrase <string> (if necessary)wlan virtual-ap <name>ssid-profile <profile>vlan <vlan>forward-mode bridgeaaa-profile <name>rap-operation {always|backup|persistent}ap-group <name>virtual-ap <name># ip access-list session "Employee-Policy"any any any permit queue lowRemote AP配置The firewall must be configured to pass NAT-T traffic (UDP port 4500) to the controller.)1、Configure a public IP address for the controller.2、Configure the VPN server on the controller. The remote AP will be a VPN client to the server.3、Configure the remote AP role.4、Configure the authentication server that will validate the username and password for the remote AP.5、Provision the AP with IPSec settings, including the username and passwordfor the AP, before you install it at the remote location.1、Cli:vlan <id>interface fastethernet <slot>/<port>switchport access vlan <id>interface vlan <id>ip address <ipaddr> <mask>2、Using the CLI to configure VPN server:vpdn group l2tpppp authentication PAPip local pool <pool> <start-ipaddr> <end-ipaddr>crypto isakmp key <key> address <ipaddr> netmask <mask>3、Using the CLI to configure the user role:(table1) (config) # user-role remote(table1) (config-role) #session-acl allowallip access-list session <policy>any any svc-papi permitany any svc-gre permitany any svc-l2tp permitany alias mswitch svc-tftp permitany alias mswitch svc-ftp permit4、Using the CLI to configure the VPN authentication profile:4.1 aaa server-group <group>auth-server <server>4.2 aaa authentication vp ndefault-role <role>server-group <group>5、Using the CLI to enable double encryption:ap system-profile <profile>double-encryptap-name <name> 需要插上远端AP后配置ap-system-profile <profile>Using the CLI to enable double encryption:ap system-profile <profile>double-encryptap-name <name>ap-system-profile <profile>Using the CLI to configure the AAA profile:aaa profile <name>initial-role <role>authentication-dot1x <dot1x-profile>dot1x-default-role <role>dot1x-server-group <group>Using the CLI to define the backup configuration in the virtual AP profile: wlan ssid-profile <profile>essid <name>opmode <method>wpa-passphrase <string> (if necessary)wlan virtual-ap <name>ssid-profile <profile>vlan <vlan>forward-mode bridgeaaa-profile <name>rap-operation {always|backup|persistent}ap-group <name>virtual-ap <name>orap-name <name>virtual-ap <name>Using the CLI to configure the DHCP server on the AP:ap system-profile <name>lms-ip <ipaddr>master-ip <ipaddr>rap-dhcp-server-vlan <vlan>wlan virtual-ap <name>ssid-profile <profile>vlan <vlan>forward-mode bridgeaaa-profile <name>rap-operation {always|backup|persistent}ap-group <name>ap-system-profile <name>virtual-ap <name>orap-name <name>ap-system-profile <name> virtual-ap <name>。
Session的有效期设置⽅式⼀:在web.xml中设置session-config如下:<session-config><session-timeout>2</session-timeout></session-config>即客户端连续两次与服务器交互间隔时间最长为2分钟,2分钟后session.getAttribute()获取的值为空API信息:session.getCreationTime() 获取session的创建时间session.getLastAccessedTime() 获取上次与服务器交互时间session.getMaxInactiveInterval() 获取session最⼤的不活动的间隔时间,以秒为单位120秒。
<!-- 登录状态过滤,可以过滤掉不需要进⾏超时验证的url --><filter><filter-name>loginFilter</filter-name><filter-class>com.software.filter.LoginFilter</filter-class></filter><filter-mapping><filter-name>loginFilter</filter-name><url-pattern>/*</url-pattern></filter-mapping><!---以上代码指明具体的路径,具体的代码见附录>⽅式⼆:在Tomcat的/conf/web.xml中session-config,默认值为:30分钟<session-config><session-timeout>30</session-timeout></session-config>⽅式三:在Servlet中设置HttpSession session = request.getSession();session.setMaxInactiveInterval(60);//单位为秒说明:1.优先级:Servlet中API设置 > 程序/web.xml设置 > Tomcat/conf/web.xml设置2.若访问服务器session超时(本次访问与上次访问时间间隔⼤于session最⼤的不活动的间隔时间)了,即上次会话结束,但服务器与客户端会产⽣⼀个新的会话,之前的session⾥的属性值全部丢失,产⽣新的sesssionId3.客户端与服务器⼀次有效会话(session没有超时),每次访问sessionId相同,若代码中设置了session.setMaxInactiveInterval()值,那么这个session的最⼤不活动间隔时间将被修改,并被应⽤为新值。
session不及时释放导致内存溢出的功能问题分析背景:做⼀个⽹站的时候,觉察服务器上⼀段⼯夫尤其不安宁,每隔⼀段⼯夫就会报”OutOfMemoryError: PermGen space”讹谬,于是⽹站也就歇菜了.安排环境:windows2003,tomcat6.0,spring mvc2.5帮助分析⼯具:jprofile6,visualvm,mat分析过程:1.⾃我察看阶段。
由于是报perm区失常,我率先想到,系统默认perm区太⼩,想想该当要调剂perm区⼤⼩,敞开catalina.bat,设置了JAVA_OPTS,JAVA_OPTS="-server -Xms512m -Xmx2048m -XX:PermSize=128M -XX:MaxNewSize=256m -XX:MaxPermSize=784m"这么设置后,模仿歇菜时候的情形举⾏压⼒测验,觉察蛮安宁的,未曾揭⽰什么问题,这时⼜精细察看代码,⼤约就未曾揭⽰频繁创⽴不可回收的草芥对象,于是就先这么吧。
过了⼀段⼯夫觉察⼜出问题了,还是perm溢出。
随后我计算下perm区曾经够⼤了,怎么还会报这个失常,此刻极其弥蒙中....2.⼯具帮助分析。
visualvm 利⽤visualvm看看perm区是否真的像传说中说的那样---"perm溢出了",看来还是恳挚点⽤apache⾃带的⼯具做压⼒测验看看是不是这个地⽅引起的测验⼯具⽤apache⾃带的 ./ab -n 100000 -c 40 http://om/class/kw-童卫⾐.html40个并发的时候perm区在30m处跌停,⼤约坚持0增长。
看来和perm区没联系。
perm区看下heap区觉察问题了 40并发下到尔后⼤约坚持5分钟顺次full gc了,这么开⼼啊,本来heap区出问题了,多个利⽤放在⼀个tomcat⾥的时候,万⼀⼀个利⽤刚好这么了,刚开始的heap,导航仪好像也没什么问题,烦闷了~~~继续弥蒙~~~~只能期待,等着出问题吧...半个⼩时过去了,还是这么....陡然觉察惊喜了。
问卷星八年级下册英语鲁教版第六单元sessionA练习1、Marie is a _______ girl.She always smiles and says hello to others. [单选题] *A. shyB. friendly(正确答案)C. healthyD. crazy2、More than one student_____absent from the class yesterday due to the flu. [单选题] *A.areB.hasC.isD.was(正确答案)3、I shall never forget the days()we worked on the farm. [单选题] *A. when(正确答案)B. whatC. whichD. on that4、John is fond of playing _____ basketball and Jack is keen on playing _____ piano. [单选题] * A./…the(正确答案)B.the…/C./…/D.the…the5、He runs so fast that no one can _______ him. [单选题] *A. keep upB. keep awayC. keep up with(正确答案)D. keep on6、Once you get on the road, here are some traffic _______ to remember. [单选题] *A. problemsB. positionsC. rules(正确答案)D. points7、?I am good at schoolwork. I often help my classmates _______ English. [单选题] *A. atC. inD. with(正确答案)8、Last week they _______ in climbing the Yuelu Mountain. [单选题] *A. succeeded(正确答案)B. succeedC. successD. successful9、--Why are you late for school today?--I’m sorry. I didn’t catch the early bus and I had to _______ the next one. [单选题] *A. wait for(正确答案)B. ask forC. care forD. stand for10、She is a girl, _______ name is Lily. [单选题] *A. whose(正确答案)B. whoC. which11、If you know the answer, _______ your hand, please. [单选题] *A. put up(正确答案)B. put downC. put onD. put in12、17.Joe is a good student and he is busy ______ his studies every day. [单选题] * A.inB.with(正确答案)C.byD.for13、—______ —()[单选题] *A. How long did you stay there?B. How much did you pay for the dress?C. How many flowers did you buy?(正确答案)D. How often did you visit your grandparents?14、Location is the first thing customers consider when_____to buy a house. [单选题] *A.planning(正确答案)B.plannedC.having plannedD.to plan15、—Look at those purple gloves! Are they ______, Mary?—No, they aren’t. ______ are pink. ()[单选题] *A. you; IB. your; MyC. yours; Mine(正确答案)D. you; Me16、Medicines are to be taken according to the doctor’s advice. [单选题] *A. 发放B. 提取C. 配方D. 服用(正确答案)17、I’m sorry there are ______ apples in the fridge. You must go and buy some right now.()[单选题] *A. a littleB. littleC. a fewD. few(正确答案)18、She returns home every year to _______ the Spring Festival. [单选题] *A. celebrate(正确答案)B. shareC. watchD. congratulate19、A small village cuts across the river. [单选题] *A. 切B. 穿过(正确答案)C. 划船D. 踢20、Many people prefer the bowls made of steel to the _____ made of plastic. [单选题] *A. itB. ones(正确答案)C. oneD. them21、68.—How ________ apples do you want?—I want two kilos. How ________ are they?—They are 5 yuan. [单选题] *A.much; manyB.many; much(正确答案)C.many; manyD.much; much22、I _______ the job because I couldn’t stand(忍受) the rules. [单选题] *A. gave inB. gave outC. gave backD. gave up(正确答案)23、Don’t _______ to close the door when you leave the classroom. [单选题] *A. missB. loseC. forget(正确答案)D. remember24、Sitting at the back of the room()a very shy girl with two bright eyes. [单选题] *A. is(正确答案)B. areC. hasD. there was25、Finally he had to break his promise. [单选题] *A. 计划B. 花瓶C. 习惯D. 诺言(正确答案)26、Sometimes Americans are said to be _____. [单选题] *A superficially friendB superficial friendC. superficial friendlyD. superficially friendly(正确答案)27、Tom’s mother will let him _______ traveling if he comes back?in five days. [单选题] *A. to goB. goesC. wentD. go(正确答案)28、_______ your help, I passed the English exam. [单选题] *A. ThanksB. Thanks to(正确答案)C. Thank youD. Thank to29、--Jimmy, you are supposed to?_______ your toys now.--Yes, mom. [单选题] *A. put upB. put onC. put away(正确答案)D. put down30、-We’ve spent too much money recently–well,it isn’t surprising. Our friend and relatives_______around all the time [单选题] *ingB. had comeC. were comingD have been coming(正确答案)。
Session No. 14________________________________________________________________________Course Title: Terrorism and Emergency ManagementSession Title: Preparedness for Major EventsTime: 3 hours________________________________________________________________________ Objectives: At the conclusion of this session, the students should be able to:14.1Describe and discuss the hazard of terrorism at major events.14.2Describe and discuss the major challenges in reducing the hazard ofterrorism at major events.14.3Describe and discuss the security and emergency managementpreparations for the 1996 Summer Olympics in Atlanta.14.4Discuss the lessons learned from the 1996 Olympics in Atlanta.________________________________________________________________________ ScopeThis session focuses on preparedness measures for major sporting, cultural,political, and social events. Events that attract thousands of participants and/orspectators and the media offer opportunity and symbolic benefit for terroristorganizations. At the same time, such events present extraordinary challenges for security officials trying to prevent attacks on individuals and on the crowds andfor emergency management officials trying to anticipate the kinds of disasters that will occur. Preparing to deal with terrorist violence at major events frequentlyinvolves building mechanisms for intergovernmental cooperation and for multi-organizational operations. The actors involved may be government officials at all levels, including officials from foreign nations in some cases; local, state, andfederal law enforcement and emergency management agencies; private andvolunteer security forces; and a complex network of nongovernmental disasteragencies. A case study of the 1996 Olympics in Atlanta is used to illustrate thechallenge that major events pose to emergency management, law enforcement,and national security agencies.________________________________________________________________________ Readings:1.Readings for Students:Brian Duffy, Erica Goode, Joannie M. Schrof, Jill Jordan Sieder, and MariaMallory, “Terror at the Olympics,” U.S. News and World Report, August 5, 1996, p.24.Jerry Adler, with Vern E. Smith, Mark Starr, Daniel Pedersen, T. Trent Gegax,Martha Brant, Karen Springen, Melinda Liu, Mark Hosenball, Michael Isikoff, and Daniel Klaidman, “Terror and ... Triumph; The Dream Turns to Nightmare,”Newsweek, August 5, 1996, p. 24.2.Readings for the Instructor:Susan Crabtree, “Gold-Medal Security,” Insight on the News, August 5, 1996, p. 7.3.Recommended Readings for the Instructor:Linda K. Richter and William L. Waugh, Jr., “Terrorism and Tourism as LogicalCompanions,” Tourism Management (December 1986): 230-238. Revised andreprinted in Managing Tourism, edited by S. Medlik (Oxford, UK: ButterworthHeinemann, 1991), pp. 318-326.________________________________________________________________________ RemarksMajor events pose many of the same problems that occur at smaller events, butthey also pose extraordinary problems because of the number of people involved,the potential impact of a terrorist attack, and the difficulty reducing vulnerabilitiesto attack. For obvious reasons, security precautions for major events are notwidely published because of the danger that the information will be used duringthe next major event. Lessons learned during each major event are discussed tosome extent, but the more common communication is through the officials whoadminister the security and emergency management programs and plan for thenext events. Many of the officials involved in the preparations for the 1996Olympics in Atlanta were involved in the 1984 Olympics in Los Angeles. Somewere in Seoul, South Korea, in 1988 and Barcelona, Spain, in 1992 to study theOlympic security and emergency management preparations, as well. Since theAtlanta Games, officials have also studied the preparedness measures in Nagano,Japan, for the 1998 Winter Olympics, and in Sydney, Australia, for the 2000Olympics, in preparation for the 2002 Winter Olympics in Salt Lake City. Whilegeography and demographics, as well as domestic and international politics, aredifferent in each country, many of the security and emergency management issues are the same.The security preparations for the 1996 Olympics in Atlanta were described insome detail in the local media and, to a much lesser extent, in the officialpublications of government agencies and the Atlanta Committee for the OlympicGames (ACOG). There is a heavy reliance on media accounts in the case studyhere, although some of the information was provided by first-hand experience and official briefings.________________________________________________________________________ Objective 14.1Describe and discuss why terrorists may choose to attack individuals or groups at a major event.Major sporting, cultural, political, and social events pose unique challenges forlaw enforcement, emergency management, and national security agencies, as well as common challenges that large cities have to deal with for lesser events, such as rock concerts and local football games.The worst case scenario is a terrorist attack on a major event using a nucleardevice, biological agent, chemical agent, or radiological material (i.e., a “weaponof mass destruction”) that resu lts in casualties numbering in the hundreds orthousands. However, even conventional weapons and homemade bombs canwreak havoc in a crowded stadium, building, or park.There are a relatively large number of major events that might attract terroristviolence, including∙the Olympic Games,∙the World Cup Soccer finals,∙the Superbowl,∙the NCAA Final Four basketball tournament,∙the World Series,∙the Stanley Cup playoffs,∙the U.S. Open tennis tournament,∙cultural exhibitions,∙party conventions,∙religious conventions and parades,∙rock and rap concerts,∙parades for “Gay Pride” or “Civil Rights” or “Women‟s Rights,”∙political protests,∙ a visit by the Pope, a foreign head of state, or an American political or social leader,∙the opening of a controversial movie or play,∙the Miss America or Miss U.S.A. pageants,∙the Academy Award, Emmy Award, Tony Award, Grammy Award, or Country Music Award programs, and∙high profile local events, including the Oklahoma-Texas, Army-Navy, Auburn-Alabama, and Notre Dame-Southern California football games. The common denominators are events that∙attract large crowds,∙attract national media attention,∙provide opportunity for terrorists to get close to their targets, and∙provide crowds and/or large metropolitan areas in which terrorists can hide while they make their preparations and make their escape.Terrorists generally seek a large audience and that is provided by the crowds and magnified by the media coverage.Crowds, particularly international crowds, provide excellent cover for terrorists because they can blend into the mass of people. Foreign terrorists may be conspicuous in crowds of Americans, unless the crowds are in locations with multi-ethnic populations. The best camouflage that a terrorist can have is a crowd in which he or she looks much like everyone else.Other risk factors include the political content of the event, the social interaction during the event, the emotional content of the event (e.g., the religious or spiritual activities), and the participants.Events that include controversial sociopolitical topics, such as Gay Rights parades or anti-abortion demonstrations, may attract opponents with extreme views and a willingness to use violence.The social interaction may create conflict or encourage violent outbursts,such as the fires and fights that have occurred at large rock concerts. Some people may find such violence exciting.The emotional content of the event may also attract extremists who will be encouraged to use violence or may simply become violent because that istheir reaction to emotional situations.The nature of the participants may also precipitate violence. The risk ofviolence may be high when there are very large crowds of young people(particularly young men), crowds that include hostile ethnic or religiousgroups, and crowds that include a large number of people who are angry.Riots have occurred at soccer (football) matches, rock concerts, and othersimilar events. Riots have also occurred at political rallies andconventions. [There may or may not be a political element in the violence, but it can be terroristic in nature. There is also scholarly literature on thetherapeutic value of sports as a means of venting political anger andfrustration.]Risk assessment is difficult given the range of motivations for domestic and international terrorist organizations and for individuals, i.e., amateurs, who may choose to use terrorism during a major event to achieve his or her political objectives.Domestic terrorists may target major events because the participants are pro-abortion, pro-environment, more liberal or conservative than the terrorists, gay or lesbian, pro-government, or associated with technology or social change or any number of other values.The assessment of vulnerabilities may be difficult because of the size of the venue, the number of venues, the location of venues, and so on. Because public access is absolutely necessary and, practically speaking, security cannot be too intrusive or slow or spectators and participants simply will not come, officials are constrained in how they can search people entering the venue.Access control, particularly in public places, is also difficult in open societies. Authoritarian governments generally have more leeway in the security measures that they can adopt.As the Centennial Olympic Park bombing in Atlanta in 1996 appears to have demonstrated, terrorists may attack an event because it is associated with an international activity. The spectators may be foreign, naturalized Americans, or simply appear to be different in culture and/or language.The rationality of domestic terrorists in the United States may be difficult to understand.For example, the Phineas Priests (described in Session 3) may choosetargets of opportunity, rather than targets with great symbolic value.Anti-government terrorists may strike almost anywhere there is agovernment facility, even a post office, or a government representative.International terrorists may choose to attack an Olympic venue or an international meeting because of the media visibility that it provides, their hostility toward the host nation, the opportunity to attack people of a nationality toward which they are hostile, or the symbolic value of attacking an event with heavy security.Officials have sometimes been so confident of their security arrangements that they have, in effect, issued challenges to anyone who felt that they could penetrate or compromise the security system. [And, if terrorists successfully attack such an event, the symbolic value will be all the higher because of the challenge.] Political groups may also choose international events because they afford opportunities to attack their opposition that they may not have in their home countries. In effect, domestic terrorism or civil war in another nation can spill over into the jurisdiction of the host nation and result in armed conflicts at major events.The worst attack during an Olympics was the Black September organization‟s murder of 11 Israeli athletes at the 1972 Olympics in Munich and that event demonstrated the vulnerability of Olympic and other venues to assault by well-trained and determined terrorists.Thus far, there has not been a terrorist attack during a major event that has caused ma ss casualties. The assumption that most terrorists want “a lot of people watching, rather than a lot of people killed” has been borne out. However, there is certainly a potential for mass casualty events.For example, a chemical agent could be used to contaminate hundreds oreven thousands of residents and visitors during a major event.A biological agent could be used to kill thousands or even millions ofpeople as those infected at the event carry the agent home.__________________________________________________________________ Questions to ask students:1.Why are major events attractive targets for terrorists?Suggested answer:Major events provide large audiences for terrorists, a variety of targets,access to targets that they might not otherwise have, crowds in which tohide before and after their attacks, and the media coverage that terroristsseek.2.What might make major events even more attractive as targets forterrorists?Suggested answer:Major events may have political, religious, or other symbolic content thatwill attract violence. Terrorists may have easier access to oppositionleaders at an event outside of their own country than at an event within it.3.Why have terrorists not caused mass casualty incidents at major events (sofar)?Suggested answer:The common wisdom is that terrorists generally want “a lot of peoplewatching rather than a lot of people dead.” However, fanatical groups,particularly religiously motivated groups and those that have little chanceof gaining popular support, may choose to kill a lot of people because they can.4.Why is the security of major events such a high priority today?Suggested answer:Although there have not been mass casualty attacks at major events, thepotential exists. Moreover, the use of biological agents could infect largenumbers of people and they may spread the infection before it is diagnosedand contained.________________________________________________________________________Objective 14.2Describe and discuss the major challenges in reducing the hazard of terrorism at major eventsMajor events pose serious challenges for security and emergency managementagencies because of the number of people involved (e.g., spectators, athletes and other participants, officials, and those responsible for running the events), thepotential for mass casualty disasters (including terrorism), and the difficultyreducing vulnerabilities because of the scale of the event.The 1996 Olympics and other major events frequently require law enforcementand security agencies to∙protect large crowds in gathering places, transit areas, and in the venues themselves,∙secure multiple venues against intrusions and attacks;∙protect many potential individual targets (e.g., social and political leaders) at the venues, at their lodging or homes, and in transit;∙protect areas in which large groups of people gather or through which they transit on foot or in vehicles;∙secure potential symbolic targets, such as statues and buildings, not necessarily involved in the major event;∙surveil possible terrorists (as well as criminals); and∙protect dignitaries as they arrive in the city or at the event site.Emergency management agencies are generally involved in the preparations formajor events because of the potential for large-scale disasters, whether caused by terrorists, the weather, structural failure, or any other natural or technicalphenomenon.As in other kinds of emergencies or disasters, local officials can usually handlesmall-scale incidents. Law enforcement and fire services agencies can implement incident command systems to accommodate the addition of more units and theinvolvement of more jurisdictions, but, as the scale of the incidents increases, the expertise of emergency management agencies is necessary to coordinate theoperation.Emergency management agencies are also involved because of the potential for a large number of lesser disasters.For example, a series of medical emergencies or security emergenciesrequires the development of priorities and systems for the effectiveallocation of resources.Major events require preparation for public health emergencies, ranging from the consequences of terrorist attacks to the effects of hot weather.For example, spectators may suffer physical stress from walking betweenvenues, dehydration from hot weather, and heart problems due to theexcitement of competitions.In some cases, venues may not be easily accessible and planning efforts might have to take into consideration the need for aerial evacuation or even boat evacuation when disasters occur.For example, Winter Olympic venues are typically located in highmountain areas with limited access by road, particularly when snow mayblock some access roads.Yachting events cover long distances and may be very far from medicaland security resources on the shore. Consequently, they typically requireaerial search and rescue capabilities.While the limited accessibility of some venues may pose problems for terrorists because they may not be able to enter the venue or escape without being seen, it may also complicate security and emergency responses, such as making it difficult to evacuate people who are at risk.Communities hosting major events seldom have the medical, law enforcement, and security capacities necessary to deal with major disasters that occur because the funding for such capacities is usually tied to their resident populations, rather than to the relatively infrequent influxes of people for major events.For example, a commun ity‟s population may double or triple when itshotel rooms fill up.Similarly, a community‟s available hospital beds may quickly fill up andits trauma facilities may be overwhelmed.Major international events attract spectators from around the world that may not be able to effectively communicate when they have health problems.Spectators and athletes at major events in developing nations, as well as theresidents, may not be sufficiently aware of the hazards present in or near thevenues.________________________________________________________________Questions to ask students:1.Why is security at major events such a challenge for federal, state, andlocal officials and event organizers?Suggested answer:Security is difficult at major events because crowds are so large, there maybe many venues to protect, access control is difficult without causingsignificant delays entering venues or causing visitors and participants tochoose not to come, and there may be alternative targets if the terroristscannot reach the ones they prefer.2.Why is venue access an important security consideration?Suggested answer:Some venues make it difficult for terrorists to access the site because it caneasily be monitored by security personnel and to egress following theirattack. Winter Olympic sites often have few access roads, for example. Bycontrast, some venues make it difficult for security because there are somany access routes. And, some venues make it difficult for emergencyresponders to gain access and for the evacuation of people who may be atrisk or injured.3.When do emergency management agencies become involved in majorevents?Suggested answer:Major events, by their very nature, may involve two or more jurisdictionsand require the resources of many organizations to provide emergencymedical care, security or law enforcement, and other essential services.________________________________________________________________________ Objective 14.3Describe and discuss the security and emergency management preparations for the 1996 Summer Olympics in Atlanta.As the opening of the 1996 Olympics approached, the comments of security officials reflected some confidence that “Atlanta will be the safest place in the world this summer” (Martz, 1996a) and some nervousness that terrorists would test their defenses.In the months prior to the 1996 Summer Olympics, there were many domestic terrorist incidents and related events, including∙the crash of TWA Flight 800 over the Long Island Sound (ultimately determined not to be of terrorist origin),∙the arrest of Militia members in Arizona in July 1996,∙ a report that Islamic terrorists planned a “suicide massacre” at Kennedy International Airport in New York in August 1995 (with security beingtightened at all three major airports in the New York City area),∙the arrest of Ted Kaczynski, the Unabomber, in April 1996,∙the arrest of two members of the “112th Battalion of the Militia-at-Large for the Republic of Georgia” outside of Macon, GA, for having pipebombs (Morganthau, 1996: 34); and∙the trial of Timothy McVeigh and Terry Nichols in Denver for the bombing of the Murrah Federal Building in April 1995.There were international incidents just prior to the 1996 Olympics, as well, including:∙the attack by the Japanese cult, Aum Shinrikyo, in the Tokyo subway system in March 1995 which killed 12,∙ a foiled plot by five Muslim terrorists to place bombs aboard 11 American airliners so that they would explode over the Pacific Ocean,∙ a series of successful and attempted bombings by terrorists in France, including the bombing of the Paris subway in October 1995 that killed 29(Kole, 1995), and∙the bombing of U.S. Air Force housing in Dhahran, Saudi Arabia, in June 1996, in which 19 servicemen were killed.While state-sponsored international terrorist attacks were judge unlikely because Iran, Iraq, Libya, and Syria were sending teams and/or officials to the Games (Martz, 1996a), there were fears of domestic and transnational terrorist attacks.The bombing of the Murrah Federal Building in Oklahoma City provided a strong stimulus for Olympic security planners because it demonstrated the fanaticism of domestic terrorist groups and their willingness to kill hundreds of people.There was some consensus among security planners that the larger threat might come from domestic, rather than international, terrorists.Prior to the Games, it was estimated that the Atlanta Committee for the Olympic Games‟ (ACOG) security budget was more than $50 million, the state ofGeor gia‟s Olympic security budget was more than $26 million, and the federal government‟s Olympic security budget was $227 million (for a total of some $303 million) (Martz, 1996a).There was considerable debate concerning the cost of the Olympics to U.S. taxpayers, including the contributions from the State of Georgia and the federal government.The security system for the Olympics was a multi-layered arrangement, ranging from the volunteers manning gates and watching the crowds to the military personnel staged at nearby bases and at the Olympic Village to respond to terrorist attacks.The ACOG, with William Rathburn as the head of security, found corporate sponsors to pay for much of the security technology, hired a security firm to handle security guards, and recruited volunteers to provide low-level security. The State Olympic Law Enforcement Command (SOLEC), with Gary McConnell as the head, coordinated state resources and helped integrate federal law enforcement and security personnel into the system.The FBI was responsible for coordinating intelligence for the security forces (and became the lead agency after the bomb exploded).The Department of Defense Joint Olympic Task Force, commanded by MG Robert Hicks, provided assistance to the civilian security forces and technical support in the event of a major terrorist attack.Because of the risk of a major terrorist incident, a partial Domestic Emergency Support Team was activated to assure that ample federal resources would be available in the event of an attack (GAO, 1997: 45). [See Session 11 on the Structure of Antiterrorism Programs for more detail on DESTs.]For example, the Department of Defense brought in a Hazardous Materials Unit for decontamination, should terrorists use biological or chemicalagents (Nelson, 1996).The Department of Health and Human Services also implemented a Metropolitan Medical Strike Team (MMST) so that a range of public health and emergency medical services would be available in the event of an attack (GAO, 1997: 61). The Atlanta MMST became a model for the teams now being developed in major U.S. cities.The White House Task Force on the Olympics (Crabtree, 1996) provided extra federal personnel to help with security and other needs.Ultimately, the security system included more than 50 federal, state, and local law enforcement agencies and about 30,000 personnel (in comparison to 45,000 security personnel at the Barcelona Olympics in 1992 and 80,000 at the Seoul Olympics in 1988) (Martz, 1996a). ACOG itself was providing approximately 16,000 private security guards (Malone, 1996)There were concerns prior to the Games about the training of security guards because of the high demand. [This issue arose again after the Centennial Park bombings because of private security companies were responsible for the park. The security companies were sued, along with AT&T, the corporate sponsor, by victims of the bombing.]There was a greater reliance on security technologies in Atlanta, rather than upon human guards (Martz, 1996a). However, because of security concerns expressed by the White House and other officials, additional federal, state, local, and private security personnel were added during the 2-3 months prior to the opening of the games.ACOG‟s security chief, Bill Ra thburn, planned to hire a single security company for the Games and have that company hire fewer, but better trained guards than were hired for the Olympic Games in Los Angeles in 1984 (where he was the head of police security planning). The plan was also to use volunteer law enforcement officers from across the United States and from overseas. They were provided food, lodging, uniforms, and transportation in exchange for their service (Martz, 1994).The participating federal agencies were the∙Federal Bureau of Investigation (FBI),∙Bureau of Alcohol, Tobacco, and Firearms (ATF),∙Central Intelligence Agency (CIA),∙Customs Service,∙Department of Defense,∙Drug Enforcement Agency,∙Federal Aviation Administration (FAA),∙Immigration and Naturalization Service,∙Secret Service,∙State Department, and∙U.S. Marshals Service (Atlanta Journal/Constitution, 1994).The state agencies included the∙Georgia Air and Army National Guard,∙Georgia Bureau of Investigation,∙Georgia State Patrol, and∙Georgia Emergency Management Agency (Atlanta Journal/Constitution, 1994).ACOG‟s contribution included∙6,000 volunteer security personnel,∙2,000 volunteer law enforcement officers,∙thousands of private security guards (Atlanta Journal/Constitution, 1994). Local agencies included∙municipal police departments,∙county sheriff‟s departments,∙Metropolitan Atlanta Rapid Transit Authority (MARTA) Police Services, ∙Atlanta Police Department,∙Georgia Tech Police Department,∙University of Georgia Public Safety Department, and∙Stone Mountain Park Police Department (Atlanta Journal/Constitution, 1994).A corporate sponsor, Sensormatic Electronics Corporation, provided approximately $25 million in services and material (Martz, 1996a).Sensormatic used a graphical security management system (its VRS-2000) to provide venue floor plans, control security devices, and provide real-time video surveillance (Chain Store Age, 1996a).“Accreditation zones” were set up with access controlled by identification badges.A chip embedded in security badges provided data on the badge holder. Also, biometric palm scanning devices were used for access to Olympic Village and other high security areas (Chain Store Age, 1996a).The rest of the corporate “security team” included∙AT&T which provided communications services;∙Bell South which provided telephone access and cellular phone service; ∙Borg-Warner Security which provided the security guards and armored transportation;∙Eastman Kodak which provided the photographic identity cards;∙IBM which provided computers to support security processes;∙Matsushita Electrical Industrial Company which provided the Panasonic cameras and monitors;∙Motorola which provided the digital radio system for security, transportation, and event management personnel; and∙Symbol Technologies which provided bar code readers for security badges (Chain Store Age, 1996b).。