Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
OpenHarmony
Third Party Openssl
提交
c6cb42e4
T
Third Party Openssl
项目概览
OpenHarmony
/
Third Party Openssl
大约 1 年 前同步成功
通知
9
Star
18
Fork
1
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
T
Third Party Openssl
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
提交
c6cb42e4
编写于
1月 02, 2006
作者:
A
Andy Polyakov
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
"Relax" prototype and rename DSO_global_lookup_func to DSO_global_lookup.
上级
2d43a894
变更
5
隐藏空白更改
内联
并排
Showing
5 changed file
with
23 addition
and
23 deletion
+23
-23
crypto/dso/dso.h
crypto/dso/dso.h
+12
-3
crypto/dso/dso_dl.c
crypto/dso/dso_dl.c
+3
-3
crypto/dso/dso_dlfcn.c
crypto/dso/dso_dlfcn.c
+5
-6
crypto/dso/dso_lib.c
crypto/dso/dso_lib.c
+1
-9
crypto/dso/dso_win32.c
crypto/dso/dso_win32.c
+2
-2
未找到文件。
crypto/dso/dso.h
浏览文件 @
c6cb42e4
...
...
@@ -173,9 +173,8 @@ typedef struct dso_meth_st
/* Return pathname of the module containing location */
int
(
*
pathbyaddr
)(
void
*
addr
,
char
*
path
,
int
sz
);
/* Perform global symbol lookup, i.e. among *all* modules,
* see commentray in dso_lib.c for further details. */
DSO_FUNC_TYPE
(
*
globallookup
)(
const
char
*
symname
);
/* Perform global symbol lookup, i.e. among *all* modules */
void
*
(
*
globallookup
)(
const
char
*
symname
);
}
DSO_METHOD
;
/**********************************************************************/
...
...
@@ -313,6 +312,16 @@ DSO_METHOD *DSO_METHOD_vms(void);
*/
int
DSO_pathbyaddr
(
void
*
addr
,
char
*
path
,
int
sz
);
/* This function should be used with caution! It looks up symbols in
* *all* loaded modules and if module gets unloaded by somebody else
* attempt to dereference the pointer is doomed to have fatal
* consequences. Primary usage for this function is to probe *core*
* system functionality, e.g. check if getnameinfo(3) is available
* at run-time without bothering about OS-specific details such as
* libc.so.versioning or where does it actually reside: in libc
* itself or libsocket. */
void
*
DSO_global_lookup
(
const
char
*
name
);
/* BEGIN ERROR CODES */
/* The following lines are auto generated by the script mkerr.pl. Any changes
* made after this point may be overwritten when the script is next run.
...
...
crypto/dso/dso_dl.c
浏览文件 @
c6cb42e4
...
...
@@ -86,7 +86,7 @@ static int dl_ctrl(DSO *dso, int cmd, long larg, void *parg);
static
char
*
dl_name_converter
(
DSO
*
dso
,
const
char
*
filename
);
static
char
*
dl_merger
(
DSO
*
dso
,
const
char
*
filespec1
,
const
char
*
filespec2
);
static
int
dl_pathbyaddr
(
void
*
addr
,
char
*
path
,
int
sz
);
static
DSO_FUNC_TYPE
dl_globallookup
(
const
char
*
name
);
static
void
*
dl_globallookup
(
const
char
*
name
);
static
DSO_METHOD
dso_meth_dl
=
{
"OpenSSL 'dl' shared library method"
,
...
...
@@ -383,9 +383,9 @@ static int dl_pathbyaddr(void *addr,char *path,int sz)
return
-
1
;
}
static
DSO_FUNC_TYPE
dl_globallookup
(
const
char
*
name
)
static
void
*
dl_globallookup
(
const
char
*
name
)
{
DSO_FUNC_TYPE
ret
;
void
*
ret
;
shl_t
h
=
NULL
;
return
shl_findsym
(
&
h
,
name
,
TYPE_UNDEFINED
,
&
ret
)
?
NULL
:
ret
;
...
...
crypto/dso/dso_dlfcn.c
浏览文件 @
c6cb42e4
...
...
@@ -99,7 +99,7 @@ static char *dlfcn_name_converter(DSO *dso, const char *filename);
static
char
*
dlfcn_merger
(
DSO
*
dso
,
const
char
*
filespec1
,
const
char
*
filespec2
);
static
int
dlfcn_pathbyaddr
(
void
*
addr
,
char
*
path
,
int
sz
);
static
DSO_FUNC_TYPE
dlfcn_globallookup
(
const
char
*
name
);
static
void
*
dlfcn_globallookup
(
const
char
*
name
);
static
DSO_METHOD
dso_meth_dlfcn
=
{
"OpenSSL 'dlfcn' shared library method"
,
...
...
@@ -446,17 +446,16 @@ static int dlfcn_pathbyaddr(void *addr,char *path,int sz)
return
-
1
;
}
static
DSO_FUNC_TYPE
dlfcn_globallookup
(
const
char
*
name
)
static
void
*
dlfcn_globallookup
(
const
char
*
name
)
{
union
{
void
*
p
;
DSO_FUNC_TYPE
f
;
}
ret
=
{
NULL
};
void
*
handle
=
dlopen
(
NULL
,
RTLD_LAZY
);
void
*
ret
=
NULL
,
*
handle
=
dlopen
(
NULL
,
RTLD_LAZY
);
if
(
handle
)
{
ret
.
p
=
dlsym
(
handle
,
name
);
ret
=
dlsym
(
handle
,
name
);
dlclose
(
handle
);
}
return
ret
.
f
;
return
ret
;
}
#endif
/* DSO_DLFCN */
crypto/dso/dso_lib.c
浏览文件 @
c6cb42e4
...
...
@@ -477,15 +477,7 @@ int DSO_pathbyaddr(void *addr,char *path,int sz)
return
(
*
meth
->
pathbyaddr
)(
addr
,
path
,
sz
);
}
/* This function should be used with caution! It looks up symbols in
* *all* loaded modules and if module gets unloaded by somebody else
* attempt to dereference the pointer is doomed to have fatal
* consequences. Primary usage for this function is to probe *core*
* system functionality, e.g. check if getnameinfo(3) is available
* at run-time without bothering about OS-specific details such as
* libc.so.versioning or where does it actually reside: in libc
* itself or libsocket. */
DSO_FUNC_TYPE
DSO_global_lookup_func
(
const
char
*
name
)
void
*
DSO_global_lookup
(
const
char
*
name
)
{
DSO_METHOD
*
meth
=
default_DSO_meth
;
if
(
meth
==
NULL
)
meth
=
DSO_METHOD_openssl
();
...
...
crypto/dso/dso_win32.c
浏览文件 @
c6cb42e4
...
...
@@ -129,7 +129,7 @@ static char *win32_name_converter(DSO *dso, const char *filename);
static
char
*
win32_merger
(
DSO
*
dso
,
const
char
*
filespec1
,
const
char
*
filespec2
);
static
int
win32_pathbyaddr
(
void
*
addr
,
char
*
path
,
int
sz
);
static
DSO_FUNC_TYPE
win32_globallookup
(
const
char
*
name
);
static
void
*
win32_globallookup
(
const
char
*
name
);
static
const
char
*
openssl_strnchr
(
const
char
*
string
,
int
c
,
size_t
len
);
...
...
@@ -773,7 +773,7 @@ static int win32_pathbyaddr(void *addr,char *path,int sz)
return
0
;
}
static
DSO_FUNC_TYPE
win32_globallookup
(
const
char
*
name
)
static
void
*
win32_globallookup
(
const
char
*
name
)
{
HMODULE
dll
;
HANDLE
hModuleSnap
=
INVALID_HANDLE_VALUE
;
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录