各位是否想到过这个问题?

star_chen 2001-08-03 10:56:36
ORACLE中提供了什么API函数可以修改用户密码?
...全文
150 9 打赏 收藏 转发到动态 举报
写回复
用AI写文章
9 条回复
切换为时间正序
请发表友善的回复…
发表回复
star_chen 2001-08-07
  • 打赏
  • 举报
回复
我找到一个函数是OCIPasswordChange,但是具体的用法有谁知道吗?
star_chen 2001-08-07
  • 打赏
  • 举报
回复
我已经搞定了,谢谢最后一位朋友
guo 2001-08-07
  • 打赏
  • 举报
回复
给你一个帮助
建议下载:
technet.oracle.com/docs/products/oracle8i/doc_library/817_doc/appdev.817/a76975.pdf

OCIPasswordChange()
Purpose
This call allows the password of an account to be changed.
Syntax
sword OCIPasswordChange ( OCISvcCtx *svchp,
OCIError *errhp,
CONST text *user_name,
ub4 usernm_len,
CONST text *opasswd,
ub4 opasswd_len,
CONST text *npasswd,
sb4 npasswd_len,
ub4 mode );
Parameters
svchp (IN/OUT)
A handle to a service context. The service context handle must be initialized and
have a server context handle associated with it.
errhp (IN)
An error handle you can pass to OCIErrorGet() for diagnostic information in the
event of an error.
user_name (IN)
Specifies the user name. It points to a character string, whose length is specified in
usernm_len. This parameter must be NULL if the service context has been initialized
with an user session handle.
usernm_len (IN)
The length of the user name string specified in user_name. For a valid user name
string, usernm_len must be non-zero.
opasswd (IN)
Specifies the user’s old password. It points to a character string, whose length is
specified in opasswd_len.
opasswd_len (IN)
The length of the old password string specified in opasswd. For a valid password
string, opasswd_len must be non-zero.
npasswd (IN)
Specifies the user’s new password. It points to a character string, whose length is
specified in npasswd_len which must be non-zero for a valid password string. If the
password complexity verification routine is specified in the user’s profile to verify
the new password’s complexity, the new password must meet the complexity
requirements of the verification function.
npasswd_len (IN)
Then length of the new password string specified in npasswd. For a valid password
string, npasswd_len must be non-zero.
mode (IN)
Can be OCI_DEFAULT and/or OCI_AUTH. If set to OCI_AUTH, the following
happens:
n If a user session context is not created, this call creates the user session context
and changes the password. At the end of the call, the user session context is not
cleared. Hence the user remains logged in.
If the user session context is already created, this call just changes the password and
the flag has no effect on the session. Hence the user still remains logged in.
Comments
This call allows the password of an account to be changed. This call is similar to
OCISessionBegin() with the following differences:
n If the user session is already established, it authenticates the account using the
old password and then changes the password to the new password
n If the user session is not established, it establishes a user session and
authenticates the account using the old password, then changes the password
to the new password.
This call is useful when the password of an account has expired and
OCISessionBegin() returns an error (ORA-28001) or warning that indicates that the
password has expired.
dragonerfish 2001-08-03
  • 打赏
  • 举报
回复
同意guo(正在消化Oracle)的说法!!!
guo 2001-08-03
  • 打赏
  • 举报
回复
alter user guo identified by abc

sqlplusk中:passw guo
Changing password for man
New password:
Retype new password:
aniugecn 2001-08-03
  • 打赏
  • 举报
回复
好像只能通过SQL来修改
hzslx 2001-08-03
  • 打赏
  • 举报
回复
gz
hailong525 2001-08-03
  • 打赏
  • 举报
回复
只能通过oracle的命令来修改用户密码!
luhongjun 2001-08-03
  • 打赏
  • 举报
回复
不知道。

34,837

社区成员

发帖
与我相关
我的任务
社区描述
MS-SQL Server相关内容讨论专区
社区管理员
  • 基础类社区
  • 二月十六
  • 卖水果的net
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧