Oracle KUPF$FILE
Version 21c

General Information
Library Note Morgan's Library Page Header
Which has the higher priority in your organization: Deploying a new database or securing the ones you already have? Looking for a website, and resources, dedicated solely to securing Oracle databases? Check out DBSecWorx.
Purpose Undocumented
AUTHID CURRENT_USER
Dependencies
DBMS_ASSERT KUPC$_API_ACK KUPC$_WORKER_GET_PWD
DBMS_DATAPUMP KUPC$_DEVICE_IDENT KUPC$_WORKER_LOG_ENTRY
DBMS_DATAPUMP_INT KUPC$_DISK_FILE KUPCC
DBMS_METADATA KUPC$_ENCODED_PWD KUPD$DATA
DBMS_METADATA_UTIL KUPC$_EXIT KUPD$DATA_INT
DBMS_PLUGTS KUPC$_FILEINFO KUPF$FILE_INT
DBMS_PRIV_CAPTURE KUPC$_FILELIST KUPM$MCP
DBMS_SYSTEM KUPC$_FILE_LIST KUPP$PROC
DBMS_SYS_ERROR KUPC$_JOBINFO KUPU$UTILITIES_INT
DBMS_UTILITY KUPC$_MDFILEPIECE KUPUTIL
KU$_DUMPFILE_INFO KUPC$_MDFILEPIECELIST KUPV$FT
KU$_DUMPFILE_ITEM KUPC$_MDREPLOFFSETSLIST KUPV$FT_INT
KU$_LOGENTRY KUPC$_MESSAGE KUPW$WORKER
KU$_LOGLINE KUPC$_SEQUENTIAL_FILE PLITBLM
KUPC$QUEUE KUPC$_WORKERERROR UTL_FILE
KUPC$QUEUE_INT KUPC$_WORKER_FILE UTL_RAW
KUPC$QUE_INT KUPC$_WORKER_FILE_LIST  
Documented No
Exceptions
Error Code Reason
ORA-39215 invalid call to routine, REQUEST_ENCPWD
First Available Not known
Security Model Owned by SYS with EXECUTE granted to PUBLIC but all functionality appears protected by an ACCESSIBLE BY clause
Source {ORACLE_HOME}/rdbms/admin/prvthpf.plb
{ORACLE_HOME}/rdbms/admin/prvtbpb.plb
Subprograms
 
ADD_DEVICE
Undocumented kupf$file.add_device(
devicename IN VARCHAR2,
volumesize IN NUMBER);
TBD
 
ADD_FILE
Undocumented kupf$file.add_file(
filename  IN VARCHAR2,
directory IN VARCHAR2,
filesize  IN NUMBER,
reusefile IN NUMBER,
is_dba    IN BOOLEAN,
read_only IN BOOLEAN,
filetype  IN NUMBER);
TBD
 
ADD_TDX_ROW_CB
Undocumented kupf$file.add_tdx_row_cb(
jobname   IN VARCHAR2,
jobowner  IN VARCHAR2,
procorder IN NUMBER,
extvalue  IN NUMBER,
filenum   IN NUMBER,
filepos   IN NUMBER);
TBD
 
ALLOCATE_DEVICE
Undocumented kupf$file.allocate_device(filename IN VARCHAR2) RETURN NUMBER;
TBD
 
CHECK_ACCESS
Undocumented kupf$file.check_access(
in_directory  IN  VARCHAR2,
in_filename   IN  VARCHAR2,
out_directory OUT VARCHAR2,
is_dba        IN  BOOLEAN,
read_only     IN  BOOLEAN,
in_filetype   IN  NUMBER,
in_trans_env  IN  BOOLEAN);
TBD
 
CHECK_FATAL_ERROR
Undocumented kupf$file.check_fatal_error REETURN BINARY_INTEGER;
TBD
 
CLOSE_CONTEXT
Calls CLOSE_CONTEXT in KUPF$FILE_INT kupf$file.close_context(ctx IN NUMBER);
TBD
 
DELETE_UNUSED_FILE_REFS
Undocumented kupf$file.delete_unused_file_refs;
TBD
 
FILE_REQUEST
Undocumented kupf$file.file_request(
wrks_wait_cnt OUT NUMBER,
max_space_req OUT NUMBER,
request_msg   IN  sys.kupc$_worker_file;
TBD
 
FILE_REQUEST_NAK
Undocumented kupf$file.file_request_nak RETURN BINARY_INTEGER;
TBD
 
FLUSH_LOB
Calls FLUSH_LOB in KUPF$FILE_INT kupf$file.flush_lob(ctx IN NUMBER);
TBD
 
GET_BLKBUF_SIZES
Calls GET_BLKBUF_SIZES in KUPF$FILE_INT kupf$file.get_blkbuf_sizes(
block_size    OUT NUMBER,
meta_buf_size OUT NUMBER,
data_buf_size OUT NUMBER);
TBD
 
GET_DEFAULT_FILENAME
Undocumented kupf$file.get_default_filename(
filename IN VARCHAR2,
filetype IN NUMBER)
RETURN VARCHAR2;
TBD
 
GET_DUMPFILE_INFO
Undocumented kupf$file.get_dumpfile_info(
filename   IN  VARCHAR2,
directory  IN  VARCHAR2,
info_table OUT sys.ku$_dumpfile_info,
filetype   OUT NUMBER);
TBD
 
GET_FILE_ATTRS
Undocumented kupf$file.get_file_attrs(
filenumber IN NUMBER,
filespec   OUT VARCHAR2,
blocksize  OUT NUMBER,
version    OUT NUMBER,
credential OUT VARCHAR2);
TBD
 
GET_FILE_LIST
Undocumented kupf$file.get_file_list RETURN sys.kupc$_filelist;
TBD
 
GET_FORMATTED_TIME
Protected by an ACCESSIBLE BY clause kupf$file.get_formatted_time RETURN VARCHAR2;
SELECT kupf$file.get_formatted_time
FROM dual;
 
GET_FULL_FILENAME
Undocumented kupf$file.get_full_filename(
TBD
 
GET_MAX_CSWIDTH
Protected by an ACCESSIBLE BY clause kupf$file.get_max_cswidth RETURN BINARY_INTEGER;
SELECT kupf$file.get_max_cswidth
FROM dual;
 
INIT
Undocumented kupf$file.init(
job_name  IN VARCHAR2,
job_owner IN VARCHAR2,
is_mcp    IN BOOLEAN,
restart   IN BOOLEAN);
TBD
 
INIT_CB
Undocumented kupf$file.init_cb(
jobname      IN  VARCHAR2,
jobowner     IN  VARCHAR2,
headersize   IN  NUMBER,
wid          IN  NUMBER,
operation    OUT NUMBER,
blocksize    OUT NUMBER,
databufsize  OUT NUMBER,
metabufsize  OUT NUMBER,
poimpfile    OUT NUMBER,
poimpmsttbl  OUT NUMBER,
poexpmsttbl  OUT NUMBER,
msttblobjnum OUT NUMBER,
traceident   OUT VARCHAR2,
instname     OUT VARCHAR2,
guid         OUT RAW,
jflgs        OUT NUMBER,
cmpalg       OUT NUMBER,
jobversion   OUT VARCHAR2,
dmpfilver    OUT NUMBER);
TBD
 
INIT_TDX_STATS
Undocumented kupf$file.init_tdx_stats(
jobname  IN VARCHAR2,
jobowner IN VARCHAR2);
TBD
 
IS_DUMPFILE_SET_CONSISTENT
Protected by an ACCESSIBLE BY clause kupf$file.is_dumpfile_set_consistent RETURN BOOLEAN;
BEGIN
  IF kupf$file.is_dumpfile_set_consistent THEN
    dbms_output.put_line('T');
  ELSE
    dbms_output.put_line('F');
  END IF;
END;
/
 IF kupf$file.is_dumpfile_set_consistent THEN
*
ERROR at line 2:
ORA-06550: line 2, column 16:
PLS-00904: insufficient privilege to access object IS_DUMPFILE_SET_CONSISTENT
ORA-06550: line 2, column 16:
PLS-00382: expression is of wrong type
ORA-06550: line 2, column 3:
PL/SQL: Statement ignored
 
JOB_MODES
Undocumented kupf$file.job_modes(
job_name    IN  VARCHAR2,
job_owner   IN  VARCHAR2,
export_mode OUT NUMBER,
import_mode OUT NUMBER);
TBD
 
LOCATE_MASTER
Undocumented kupf$file.locate_master(
master_found        OUT BOOLEAN,
dumpset_enc_columns OUT BOOLEAN,
dumpset_db_version  OUT NUMBER);
TBD
 
LOG_MESSAGES
Undocumented kupf$file.log_messages(
msgtype   IN NUMBER,
msgline1  IN VARCHAR2,
msgline2  IN VARCHAR2,
msgline3  IN VARCHAR2,
msgline4  IN VARCHAR2,
msgline5  IN VARCHAR2,
msgline6  IN VARCHAR2,
msgline7  IN VARCHAR2,
msgline8  IN VARCHAR2,
msgline9  IN VARCHAR2,
msgline10 IN VARCHAR2);
TBD
 
MARK_FILES_AS_UNUSABLE
Undocumented kupf$file.mark_files_as_unusable(worker_id IN NUMBER) RETURN NUMBER;
TBD
 
MASTER_TABLE_UNLOAD_STARTED
Undocumented kupf$file.master_table_unload_started;
TBD
 
OPEN_CONTEXT
Calls OPEN_CONTEXT in KUPF$FILE_INT kupf$file.open_context(
process_corder IN NUMBER,
file_piece_num IN NUMBER)
RETURN NUMBER;
TBD
 
READ_LOB
Undocumented kupf$file.read_lob(
ctx IN BINARY_INTEGER,
mdfilepieces  IN     sys.kupc$_mdfilepiecelist,
blocksize     IN     BINARY_INTEGER,
charsetid     IN     BINARY_INTEGER,
mdencoding    IN     BINARY_INTEGER,
version       IN     BINARY_INTEGER,
dstlob        IN     CLOB,
srclob        IN     BLOB,
mdreploffsets IN OUT sys.kupc$_mdreploffsetslist,
datalosswarn  OUT    BOOLEAN,
datalossmore  OUT    BOOLEAN);
TBD
 
RELEASE_FILE
Undocumented kupf$file.parse_filename(
filename  IN  VARCHAR2,
dirpath   OUT VARCHAR2,
name      OUT VARCHAR2,
extension OUT VARCHAR2,
version   OUT VARCHAR2,
trans_env IN  BOOLEAN);
TBD
 
RELEASE_FILES
Undocumented kupf$file.release_files;
TBD
 
REQUEST_ENCPWD
The demo at right if allowed to do so raises an ORA-39215

The reason this demo is published is that the anonymous block demonstrates a typical response of an attacker trying to see if they have found an exposed vulnerability.
kupf$file.request_encpwd(
wid       IN  NUMBER,
encpwd    OUT RAW,
encpwdlen OUT NUMBER);
DECLARE
 r RAW(32767);
 n NUMBER;
BEGIN
  FOR i IN 1 .. 1024000 LOOP
    BEGIN
      kupf$file.request_encpwd(i, r, n);
      dbms_output.put_line(i);
      dbms_output.put_line(r);
      dbms_output.put_line(n);
    EXCEPTION
--      WHEN OTHERS THEN RAISE;
      WHEN OTHERS THEN NULL;
    END;
  END LOOP;
END;
/
 
REQUEST_FILE
Undocumented kupf$file.request_file(
wid        IN     NUMBER,
sid        IN     NUMBER,
inflags    IN     NUMBER,
minsize    IN     NUMBER,
blocksize     OUT NUMBER,
outflags      OUT NUMBER,
maxfilesize   OUT NUMBER,
filename      OUT VARCHAR2,
filenum    IN OUT NUMBER,
filepos    IN OUT NUMBER,
allocsize  IN OUT NUMBER,
credential    OUT VARCHAR2
TBD
 
RESET_EOF
Undocumented kupf$file.reset_eof;
TBD
 
SET_DEBUG
Undocumented kupf$file.set_debug(
jobflgs    IN NUMBER,
debugident IN VARCHAR2);
TBD
 
SET_LOG_INFO
Undocumented kupf$file.set_log_info(
log_dir  IN VARCHAR2,
log_name IN VARCHAR2);
TBD
 
TERM
Undocumented

Overload 1
kupf$file.term(
defining_state IN BOOLEAN,
delete_files   IN BOOLEAN);
TBD
Undocumented

Overload 2
kupf$file.term;
TBD
 
TRACE
Undocumented kupf$file.trace(
ident IN VARCHAR2,
str   IN VARCHAR2);
TBD
 
UPD_FILE_COMP_BYTES
Undocumented kupf$file.upd_file_comp_bytes(
jobname    IN VARCHAR2,
jobowner   IN VARCHAR2,
filenumber IN NUMBER,
allocsize  IN NUMBER);
TBD
 
UPD_TDX_FILEINFO_CB
Undocumented kupf$file.upd_tdx_fileinfo_cb(
jobname   IN VARCHAR2,
jobowner  IN VARCHAR2,
procorder IN NUMBER,
extvalue  IN NUMBER,
dmplen    IN NUMBER,
dmporl    IN NUMBER,
dmpalc    IN NUMBER);
TBD
 
UPD_TDX_STATS_CB
Undocumented kupf$file.upd_tdx_stats_cb(
jobname     IN VARCHAR2,
jobowner    IN VARCHAR2,
procorder   IN NUMBER,
extvalue    IN NUMBER,
rowscomp    IN NUMBER,
errorcnt    IN NUMBER,
granulecnt  IN NUMBER,
elapsedtime IN NUMBER);
TBD
 
VERIFY_DUMPFILE_SET
Undocumented kupf$file.verify_dumpfile_set(
device_ident_message IN  sys.kupc$_device_ident,
is_dumpset_complete  OUT BOOLEAN,
current_job_mode     OUT NUMBER,
response_wait_count  OUT NUMBER,
seq_file_message     OUT sys.kupc$_sequential_file);
TBD
 
WRITE_LOB
Undocumented kupf$file.write_lob(
ctx          IN     BINARY_INTEGER,
lob          IN     CLOB,
mdfilepieces IN OUT sys.kupc$_mdfilepiecelist,
transtime       OUT BINARY_INTEGER);
TBD

Related Topics
Built-in Functions
Built-in Packages
Database Security
KUPF$FILE_INT
What's New In 19c
What's New In 20c-21c

Morgan's Library Page Footer
This site is maintained by Dan Morgan. Last Updated: This site is protected by copyright and trademark laws under U.S. and International law. © 1998-2022 Daniel A. Morgan All Rights Reserved
  DBSecWorx