Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
libnice
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
cpp-libs
libnice
Commits
23847045
Commit
23847045
authored
Aug 14, 2008
by
Olivier Crête
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Replace the SERVER attribute with the SOFTWARE attribute per draft 17
parent
dda21433
Changes
7
Show whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
13 additions
and
13 deletions
+13
-13
stun/stun3489bis.c
stun/stun3489bis.c
+4
-4
stun/stun3489bis.h
stun/stun3489bis.h
+1
-1
stun/stunagent.c
stun/stunagent.c
+4
-4
stun/stunagent.h
stun/stunagent.h
+1
-1
stun/stunmessage.h
stun/stunmessage.h
+1
-1
stun/tools/stund.c
stun/tools/stund.c
+1
-1
stun/usages/bind.c
stun/usages/bind.c
+1
-1
No files found.
stun/stun3489bis.c
View file @
23847045
...
@@ -74,10 +74,10 @@ bool stun_has_cookie (const StunMessage *msg)
...
@@ -74,10 +74,10 @@ bool stun_has_cookie (const StunMessage *msg)
}
}
int
stun_message_append_s
erver
(
StunMessage
*
msg
)
int
stun_message_append_s
oftware
(
StunMessage
*
msg
)
{
{
static
const
char
s
erver
[]
=
PACKAGE_STRING
;
static
const
char
s
oftware
[]
=
PACKAGE_STRING
;
// assert (strlen (s
erver
) < 128);
// assert (strlen (s
oftware
) < 128);
return
stun_message_append_string
(
msg
,
STUN_ATTRIBUTE_S
ERVER
,
server
);
return
stun_message_append_string
(
msg
,
STUN_ATTRIBUTE_S
OFTWARE
,
software
);
}
}
stun/stun3489bis.h
View file @
23847045
...
@@ -56,7 +56,7 @@ uint32_t stun_fingerprint (const uint8_t *msg, size_t len);
...
@@ -56,7 +56,7 @@ uint32_t stun_fingerprint (const uint8_t *msg, size_t len);
bool
stun_has_cookie
(
const
StunMessage
*
msg
);
bool
stun_has_cookie
(
const
StunMessage
*
msg
);
int
stun_message_append_s
erver
(
StunMessage
*
msg
);
int
stun_message_append_s
oftware
(
StunMessage
*
msg
);
#endif
/* _STUN_3489BIS_H */
#endif
/* _STUN_3489BIS_H */
...
...
stun/stunagent.c
View file @
23847045
...
@@ -354,8 +354,8 @@ bool stun_agent_init_response (StunAgent *agent, StunMessage *msg,
...
@@ -354,8 +354,8 @@ bool stun_agent_init_response (StunAgent *agent, StunMessage *msg,
stun_message_get_method
(
request
),
id
))
{
stun_message_get_method
(
request
),
id
))
{
if
(
agent
->
compatibility
==
STUN_COMPATIBILITY_3489BIS
&&
if
(
agent
->
compatibility
==
STUN_COMPATIBILITY_3489BIS
&&
agent
->
usage_flags
&
STUN_AGENT_USAGE_ADD_S
ERVER
)
{
agent
->
usage_flags
&
STUN_AGENT_USAGE_ADD_S
OFTWARE
)
{
stun_message_append_s
erver
(
msg
);
stun_message_append_s
oftware
(
msg
);
}
}
return
TRUE
;
return
TRUE
;
}
}
...
@@ -386,8 +386,8 @@ bool stun_agent_init_error (StunAgent *agent, StunMessage *msg,
...
@@ -386,8 +386,8 @@ bool stun_agent_init_error (StunAgent *agent, StunMessage *msg,
stun_message_get_method
(
request
),
id
))
{
stun_message_get_method
(
request
),
id
))
{
if
(
agent
->
compatibility
==
STUN_COMPATIBILITY_3489BIS
&&
if
(
agent
->
compatibility
==
STUN_COMPATIBILITY_3489BIS
&&
agent
->
usage_flags
&
STUN_AGENT_USAGE_ADD_S
ERVER
)
{
agent
->
usage_flags
&
STUN_AGENT_USAGE_ADD_S
OFTWARE
)
{
stun_message_append_s
erver
(
msg
);
stun_message_append_s
oftware
(
msg
);
}
}
if
(
stun_message_append_error
(
msg
,
err
)
==
0
)
{
if
(
stun_message_append_error
(
msg
,
err
)
==
0
)
{
return
TRUE
;
return
TRUE
;
...
...
stun/stunagent.h
View file @
23847045
...
@@ -82,7 +82,7 @@ typedef enum {
...
@@ -82,7 +82,7 @@ typedef enum {
#define STUN_AGENT_USAGE_SHORT_TERM_CREDENTIALS 0x0001
#define STUN_AGENT_USAGE_SHORT_TERM_CREDENTIALS 0x0001
#define STUN_AGENT_USAGE_LONG_TERM_CREDENTIALS 0x0002
#define STUN_AGENT_USAGE_LONG_TERM_CREDENTIALS 0x0002
#define STUN_AGENT_USAGE_USE_FINGERPRINT 0x0004
#define STUN_AGENT_USAGE_USE_FINGERPRINT 0x0004
#define STUN_AGENT_USAGE_ADD_S
ERVER
0x0008
#define STUN_AGENT_USAGE_ADD_S
OFTWARE
0x0008
#define STUN_AGENT_USAGE_IGNORE_CREDENTIALS 0x0010
#define STUN_AGENT_USAGE_IGNORE_CREDENTIALS 0x0010
#define STUN_AGENT_USAGE_FORCE_VALIDATER 0x0020
#define STUN_AGENT_USAGE_FORCE_VALIDATER 0x0020
...
...
stun/stunmessage.h
View file @
23847045
...
@@ -122,7 +122,7 @@ typedef enum
...
@@ -122,7 +122,7 @@ typedef enum
/* Optional attributes */
/* Optional attributes */
/* 0x8000-0x8021 */
/* reserved */
/* 0x8000-0x8021 */
/* reserved */
STUN_ATTRIBUTE_S
ERVER
=
0x8022
,
/* RFC3489bis-11
*/
STUN_ATTRIBUTE_S
OFTWARE
=
0x8022
,
/* RFC3489bis-17
*/
STUN_ATTRIBUTE_ALTERNATE_SERVER
=
0x8023
,
/* RFC3489bis-11 */
STUN_ATTRIBUTE_ALTERNATE_SERVER
=
0x8023
,
/* RFC3489bis-11 */
STUN_ATTRIBUTE_REFRESH_INTERVAL
=
0x8024
,
/* wing-nat-control-04 */
STUN_ATTRIBUTE_REFRESH_INTERVAL
=
0x8024
,
/* wing-nat-control-04 */
/* 0x8025 */
/* reserved */
/* 0x8025 */
/* reserved */
...
...
stun/tools/stund.c
View file @
23847045
...
@@ -265,7 +265,7 @@ static int run (int family, int protocol, unsigned port)
...
@@ -265,7 +265,7 @@ static int run (int family, int protocol, unsigned port)
stun_agent_init
(
&
agent
,
known_attributes
,
stun_agent_init
(
&
agent
,
known_attributes
,
STUN_COMPATIBILITY_3489BIS
,
STUN_AGENT_USAGE_ADD_S
ERVER
|
STUN_COMPATIBILITY_3489BIS
,
STUN_AGENT_USAGE_ADD_S
OFTWARE
|
STUN_AGENT_USAGE_USE_FINGERPRINT
);
STUN_AGENT_USAGE_USE_FINGERPRINT
);
for
(;;)
for
(;;)
...
...
stun/usages/bind.c
View file @
23847045
...
@@ -168,7 +168,7 @@ StunUsageBindReturn stun_usage_bind_run (const struct sockaddr *srv,
...
@@ -168,7 +168,7 @@ StunUsageBindReturn stun_usage_bind_run (const struct sockaddr *srv,
stun_agent_init
(
&
agent
,
STUN_ALL_KNOWN_ATTRIBUTES
,
stun_agent_init
(
&
agent
,
STUN_ALL_KNOWN_ATTRIBUTES
,
STUN_COMPATIBILITY_3489BIS
,
STUN_COMPATIBILITY_3489BIS
,
STUN_AGENT_USAGE_ADD_S
ERVER
|
STUN_AGENT_USAGE_ADD_S
OFTWARE
|
STUN_AGENT_USAGE_USE_FINGERPRINT
);
STUN_AGENT_USAGE_USE_FINGERPRINT
);
len
=
stun_usage_bind_create
(
&
agent
,
&
req
,
req_buf
,
sizeof
(
req_buf
));
len
=
stun_usage_bind_create
(
&
agent
,
&
req
,
req_buf
,
sizeof
(
req_buf
));
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment