oracle文件夹cwallet,Oracle Wallet
Oracle Wallet是用来加密解密的,前两天做的项目中用到了这个技术,现把一些用到的东西总结一下。
原文如下:
Our application does a web service call
(from db to app server) to generate reports. Since SSL is used in
prod, I think Oracle wallet needs to be setup in the db server for
the web service calls to get through.
Here's a sample code that we can use to
test:
SQL> set define
off
SQL> set serverout
on
SQL> declare
vHttpReq utl_http.req;
begin
vHttpReq := utl_http.begin_request
('https://10.37.240.202/emagine/admin/ws/report.php
'||'?'||'target=report&io=461&io2=462&io3=463&code=34',
'GET');
end; 2 3 4 5
6 /
declare
*
ERROR at line 1:
ORA-29273: HTTP request failed
ORA-06512: at "SYS.UTL_HTTP", line
1130
ORA-29024: Certificate validation
failure
ORA-06512: at line 4
I've already downloaded the site's
certificate in My Documents folder in the RDP server.
下面是我的解决方法(我不知道他的证书是怎么来的,以后有机会深究一下):
1.I have already create a
wallet.
orapki wallet create -wallet
$ORACLE_HOME/network/admin/wallet1 -pwd elcaro_2011
2.You can use https certificate like
this:
orapki wallet add -wallet
$ORACLE_HOME/network/admin/wallet1 -trusted_cert -cert
/home/oracle/wallet/CA_cert.cer
3.this procedure is the demo of how to use
this wallet.
create or replace procedure
get_realtime_account_data is
req UTL_HTTP.REQ;
resp UTL_HTTP.RESP;
val varchar2(2000);
real_records
datacenter.common_utils.STRING_LIST;
fields
datacenter.common_utils.STRING_LIST;
d_date date := to_date(to_char(sysdate,
'yyyy-mm-dd hh24:mi') ||
':00',
'yyyy-mm-dd hh24:mi:ss'); begin
UTL_HTTP.SET_WALLET('file:/home/oracle/wallet',
'wallet');
req :=
UTL_HTTP.BEGIN_REQUEST('https://192.168.127.1/GameMaster/GetServerInfo.aspx');
resp :=
UTL_HTTP.GET_RESPONSE(req);
utl_http.read_line(resp, val,
true);
utl_http.end_response(resp);
real_records :=
datacenter.common_utils.EXPLODE(val, '|');
for i in 1 .. real_records.count
loop
fields :=
datacenter.common_utils.EXPLODE(real_records(i), '/');
insert into
stat_realtime_player_count
values
(d_date, fields(1), '',
fields(2));
end loop;
commit;
EXCEPTION
WHEN utl_http.end_of_body THEN
utl_http.end_response(resp);
end get_realtime_account_data;
用下面的命令可以看到关于wallet用法的帮助
[oracle@au390 EMAGPROD]$ orapki wallet
Oracle PKI Tool : Version 11.2.0.1.0 - Production
Copyright (c) 2004, 2009, Oracle and/or its affiliates. All rights
reserved.
wallet:
create [-wallet [wallet]] [[-pwd ] [-auto_login|-auto_login_local]]
| [-auto_login_only]
display [-wallet [wallet]]
[-pwd ]
change_pwd [-wallet [wallet]] [-oldpwd ] [-newpwd ]
add [-wallet [wallet]]
[512|1024|2048|4096]] [-dn [dn]]>
[mm/dd/yyyy] -valid_until [mm/dd/yyyy]]
[-serial_file ] | [-serial_num ]>
[-trusted_cert|-user_cert]> [-pwd ] |
[-auto_login_only]
remove [-wallet [wallet]] [-dn [dn]]
[-trusted_cert_all|-trusted_cert|-user_cert|-cert_req]
[-pwd ] | [-auto_login_only]
export [-wallet [wallet]] [-dn [dn]] [-cert [filename] | -request
[filename]] [-pwd ]
export_trust_chain [-wallet [wallet]] [-certchain [filename]] [-dn
[user_cert_dn]] [-pwd ]
upload [-wallet [wallet]] [-ldap [host:port]] [-user [user]]
[-userpwd [userpwd]] [-pwd ]
download [-wallet [wallet]] [-ldap [host:nonsslport]] [-user
[user]] [-userpwd [userpwd]] [-pwd ]
jks_to_pkcs12 [-wallet [wallet]] [-pwd ] [-keystore [keystore]]
[-jkspwd [jkspwd]]
pkcs12_to_jks [-wallet [wallet]] [-pwd ] [-jksKeyStoreLoc
-jksKeyStorepwd ]
[-jksTrustStoreLoc -jksTrustStorepwd ]
p11_add [-wallet [wallet]] [-p11_lib ] [-p11_tokenlabel ]
[-p11_tokenpw ] [-p11_certlabel ] [-pwd ]
p11_verify [-wallet [wallet]] [-pwd ]
help
oracle文件夹cwallet,Oracle Wallet相关推荐
- window 10 删除带有管理员权限的Oracle文件夹
因为文件已经被删除就不附图解释了 因为文件安装的方式错误,所以本是按照正常步骤卸载Oracle,前面的禁用Orace服务与删除Oracle注册表都没有出错,但到最后一步---------Oracle文 ...
- oracle中app文件夹下,Oracle Form开发之folder(文件夹)功能开发(一)
一.模板制作:YSFOLDER.FMB 打开TEMPLATE.FMB,如果打开的是APPSTAND.FMB,以下步骤省略: 1.FORM级触发器: 1.在WHEN-NEW-FORM-INSTANCE后 ...
- c盘oracle文件夹,C盘的用户文件夹转移到其他分区
最近系统坏了,也不知道什么原因, 没细找, 就直接解压windows文件夹复原了, 什么也没丢, 挺方便的, 这里就分享给大家把, 以后系统坏了,也不怕丢东西了. C盘中除了windows,其他都可以 ...
- bak文件转oracle文件,如何在Oracle 11g中恢复.bak文件(How to restore .bak file in oracle 11g)...
如何在Oracle 11g中恢复.bak文件(How to restore .bak file in oracle 11g) 我有Oracle 11g备份文件(.bak文件)如何在Oracle 11g ...
- oracle文件存储方式,oracle文件存储介质介绍
oracle文件存储介质介绍 1. 前言 现在我们用户中随着ORACLE的应用越来越复杂,对于ORACLE文件存储也再不象以前这么简单D盘,C盘的规划,特别是linux环境加上RAC的应用对存储介质有 ...
- oracle下的inventory文件夹,在 Oracle Home 目录中重建Central Inventory(oraInventory)的步骤...
--摘抄于Metalink 在Oracle Home目录中重建Central Inventory(oraInventory)的步骤 适用于: Oracle Database - Standard Ed ...
- EAS7.5服务器文件夹备份,ORACLE+EAS数据备份与恢复参考
<ORACLE+EAS数据备份与恢复参考>由会员分享,可在线阅读,更多相关<ORACLE+EAS数据备份与恢复参考(9页珍藏版)>请在人人文库网上搜索. 1.一.服务器环境描述 ...
- 数据库oracle文件怎么打开,Oracle某个数据文件损坏,如何打开数据库-数据库专栏,ORACLE...
某个数据文件损坏,如何打开数据库? 系统环境: 1.操作系统:windows 2000 server,机器内存128m 2.数据库: oracle 8i r2 (8.1.6) for nt 企业版 3 ...
- oracle 10g/11g 命令对照,日志文件夹对照
oracle 10g/11g 命令对照,日志文件夹对照 oracle 11g 中不再建议使用的命令 Deprecated Command Replacement Commands crs_st ...
最新文章
- javascript高级程序设计之引用类型
- JAVA 正则表达式 分组
- 现代操作系统: 第五章 输入/输出
- java rocketmq消费_rocketmq消费负载均衡--push消费详解
- Vmware centos无法连接网络
- java ee 类切换_eclipse的工程类型切换
- 【VMCloud云平台】SCOM配置(额外篇)-应用可用性150点实时性测试
- 使用Go实现Socket服务端和客户端通信
- 跨平台iOS自动化测试工具——tidevice安装及使用
- 《黑客防线》《黑客X档案》《非安全-黑客手册》电子刊下载(最全版)
- 操作系统产品密钥查看方法
- 微机大作业—— 24秒倒计时器
- watch gt3 鸿蒙,华为matepad pro2和watchGT3系列即将发布!
- 刚体质量分布与牛顿-欧拉方程
- Altium Designer快捷键布线无法实现网络线自动编号
- 基于Xilinx Kintex-7 FPGA K7 XC7K325T PCIeX8 四路光纤卡226
- 智慧灌区、水利、闸门控制、智慧监控、水质监测、气象站、水质站、灌区监测、渠道监测、水情监测、降水监测、渠道水位、流量、水量、干渠、支渠、枢纽闸门、预警管理、工程管理、任务管理、系统管理、axure原型
- 如何用python调用百度云接口实例
- Android Fonts
- 【题解】P4707 重返现世
热门文章
- R使用abline()函数在图中添加额外的直线
- 谱聚类 Spectral Clustering
- 影像组学视频学习笔记(15)-ROC曲线及其绘制、Li‘s have a solution and plan.
- Hbase表结构设计
- 用c语言按颜色对图像进行分类,【leetcode C语言实现】75_颜色分类
- python HDF5 h5py 的用法
- python opencv 彩色图非局部平均去噪
- Navicat 2003-can't connect to MYSQL server on 'localhost'(10061)
- 在Linux上使用图形界面的GitHub Desktop
- 2020-09-21C++学习笔记之与C语言区别和加强——四种const意义(const int a; int const b; const int *c; int * const d)