Examples of OracleWallProvider


Examples of com.alibaba.druid.wall.spi.OracleWallProvider

public class WallDenyTableTest extends TestCase {

    public void testORACLE() throws Exception {
        String sql = "SELECT *FROM T UNION SELECT F1, F2 FROM SYS.ABC";

        OracleWallProvider provider = new OracleWallProvider();
        Assert.assertFalse(provider.checkValid(sql));

    }
View Full Code Here

Examples of com.alibaba.druid.wall.spi.OracleWallProvider

        WallTableStat tableStat = provider.getTableStat("t");
        Assert.assertEquals(1, tableStat.getDeleteCount());
    }

    public void testOracle() throws Exception {
        WallProvider provider = new OracleWallProvider();
        Assert.assertTrue(provider.checkValid(sql));
        WallTableStat tableStat = provider.getTableStat("t");
        Assert.assertEquals(1, tableStat.getDeleteCount());
    }
View Full Code Here

Examples of com.alibaba.druid.wall.spi.OracleWallProvider

        WallTableStat tableStat =  provider.getTableStat("t");
        Assert.assertEquals(1, tableStat.getUpdateCount());
    }
   
    public void testOracle() throws Exception {
        WallProvider provider = new OracleWallProvider();
        Assert.assertTrue(provider.checkValid(sql));
        WallTableStat tableStat =  provider.getTableStat("t");
        Assert.assertEquals(1, tableStat.getUpdateCount());
    }
View Full Code Here

Examples of com.alibaba.druid.wall.spi.OracleWallProvider

        WallTableStat tableStat =  provider.getTableStat("t");
        Assert.assertEquals(1, tableStat.getInsertCount());
    }
   
    public void testOracle() throws Exception {
        WallProvider provider = new OracleWallProvider();
        Assert.assertTrue(provider.checkValid(sql));
        WallTableStat tableStat =  provider.getTableStat("t");
        Assert.assertEquals(1, tableStat.getInsertCount());
    }
View Full Code Here

Examples of com.alibaba.druid.wall.spi.OracleWallProvider

        WallTableStat tableStat =  provider.getTableStat("t");
        Assert.assertEquals(1, tableStat.getCreateCount());
    }
   
    public void testOracle() throws Exception {
        WallProvider provider = new OracleWallProvider();
        provider.getConfig().setCreateTableAllow(true);
       
        Assert.assertTrue(provider.checkValid(sql));
        WallTableStat tableStat =  provider.getTableStat("t");
        Assert.assertEquals(1, tableStat.getCreateCount());
    }
View Full Code Here

Examples of com.alibaba.druid.wall.spi.OracleWallProvider

        } else if (JdbcUtils.ORACLE.equals(dbType) || JdbcUtils.ALI_ORACLE.equals(dbType)) {
            if (config == null) {
                config = new WallConfig(OracleWallProvider.DEFAULT_CONFIG_DIR);
            }

            provider = new OracleWallProvider(config);
        } else if (JdbcUtils.SQL_SERVER.equals(dbType) || JdbcUtils.JTDS.equals(dbType)) {
            if (config == null) {
                config = new WallConfig(SQLServerWallProvider.DEFAULT_CONFIG_DIR);
            }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.