
Mysql 数据库
My_Java_Life
这个作者很懒,什么都没留下…
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
换行导致无法模拟SQL注入
在使用 Mybatis 时,取值时,应尽量使用 # 取值,因为当使用 $ 取值时,会出现SQL注入的风险。 比如下面的登录校验语句,如果用户名输入 '' or 1=1 #,可以实现SQL注入 <select id="getUserByNameAndPwd" resultType="com.cry.mall.entity.User"> select * from c_user where user_name = ${userName} and原创 2021-05-16 21:43:57 · 331 阅读 · 0 评论 -
Spring中数据库技术--获得DataSource
Spring中数据库技术--获得DataSource 一、JNDI获得DataSource(对服务器有一定的依赖) 使用JNDI方法获得DataSource,程序必须运行在支持JNDI服务的容器中,如Tomcat、WebLogic等。 1、SpringJNDI数据源配置信息: <!-- java:comp/env/ 默认前缀部分 jcptDataSourceJNDI原创 2015-10-15 23:09:31 · 2800 阅读 · 0 评论 -
查询练习
创建表空间 scott_space create tablespace scott_space datafile 'D:\JavaLife\oracle\scott_data.dbf' size 100m; 创建用户 scott/1 create user scott identified by 1 default tablespace scott_space account unlock; ...原创 2015-10-10 20:06:19 · 431 阅读 · 0 评论