Age | Commit message (Collapse) | Author | Files | Lines |
|
gnutls dependency is only required when wispr is enabled. Currently
connman is build with flag --disable-wispr so gnutls is not required.
This patch removes gnutls dependency from spec file.
We'll find alternative for gnutls later and add that together with
patches related to captive portal
Change-Id: I23491ec67c365b4bc89c6231cc0a581431208f5a
Signed-off-by: Saurav Babu <saurav.babu@samsung.com>
|
|
- Fixed NTP service's DNS resolving failure in Hive project.
- Do not turn "wlan0" interface down in cleanup_devices().
- Set resource limits "RLIMIT_NOFILE" for a process.
- After appending a file, fflush and fsync all modified in-core data of the file.
Change-Id: I2767b3302d6204d066fe2075027828ff209d0ee0
Signed-off-by: Niraj Kumar Goit <niraj.g@samsung.com>
|
|
desc : some of AP sends the DNS response even though AP is not connected
with internet service. In this case, DNS response address is not proper
- it is the private address. So, we check the address validation before
sending the internet url.
Change-Id: I5dae725e931e5d66072bb809c8cce489ffa79379
Signed-off-by: Niraj Kumar Goit <niraj.g@samsung.com>
|
|
Change-Id: I2cbd57173eea6720389d60324b4e6f374e66611d
Signed-off-by: hyunuktak <hyunuk.tak@samsung.com>
|
|
Change-Id: I291b210c7f241492df945d565d9d44c7ad57054f
Signed-off-by: hyunuktak <hyunuk.tak@samsung.com>
|
|
Signed-off-by: hyunuktak <hyunuk.tak@samsung.com>
Change-Id: I84a42375b5c59739e4caca1f726699ea7647ef17
|
|
|
|
It will check first if the response belongs to a query,
before interpreting any of its content (rcode, count...).
|
|
Fixes BMC#25973
In the case one of the resolving failed, the query is removed and
destroyed from the queue. So the responses of the requests sent to
the other namerservers - which might be successful - will thus be
lost since they cannot be matched anymore to their initial request.
|
|
parse_response() will eventually call sort_and_return_results() which in turn
will call the result function. But the result function might cancel the gresolv.
At that point all queries belonging to this gresolv are destroyed. Returning back
to parse_response(), it calls again destroy_query() on an already destroyed one.
Thus leading to a crash.
Same issue with query_timeout()
Reported by Daniel Wagner
|
|
Program received signal SIGSEGV, Segmentation fault.
Backtrace:
0 0x00000000004219fe in _debug (resolv=0x75f9a0, file=0x497267 "gweb/gresolv.c",
caller=0x497598 "destroy_lookup",
format=0x497278 "lookup %p id %d ipv4 %p ipv6 %p") at gweb/gresolv.c:136
1 0x0000000000421ac5 in destroy_lookup (lookup=0x760e40) at gweb/gresolv.c:154
2 0x00000000004224ce in sort_and_return_results (lookup=0x760e40) at gweb/gresolv.c:520
3 0x0000000000422597 in query_timeout (user_data=0x760510) at gweb/gresolv.c:542
4 0x00007ffff7b1b26b in g_timeout_dispatch (source=0x760ea0, callback=<optimized out>,
user_data=<optimized out>) at gmain.c:4095
5 0x00007ffff7b1a643 in g_main_dispatch (context=0x6f5110) at gmain.c:2784
6 g_main_context_dispatch (context=0x6f5110) at gmain.c:3288
7 0x00007ffff7b1a988 in g_main_context_iterate (dispatch=1, block=<optimized out>,
context=0x6f5110, self=<optimized out>) at gmain.c:3359
8 g_main_context_iterate (context=0x6f5110, block=<optimized out>, dispatch=1,
self=<optimized out>) at gmain.c:3296
9 0x00007ffff7b1ade5 in g_main_loop_run (loop=0x6f4fe0) at gmain.c:3553
10 0x0000000000442a5f in main (argc=1, argv=0x7fffffffdea8) at src/main.c:705
Reported by Daniel Wagner
|
|
Use for all memory allocation/dealocation operation the glib
functions. This allows us to use g_mem_profile().
|
|
|
|
The file and function name are printed in debug prints.
|
|
The order of actions is important here.
|
|
We must close the channel when freeing the resolver object,
otherwise we might still receive data when the resolver has been
freed already.
Fixes BMC#25757
|
|
|
|
The file and function names are printed in debug prints.
|
|
The call to g_resolv_cancel_lookup() will do nothing
because we just removed the lookup from the queue.
The fix is to remove the lookup directly and not call
the cancel function.
|
|
Remove all lookups found in queue when GResolv object is removed.
|
|
We must remove the lookup from lookup queue and query from query queue
before calling user callback. The callback might unref the GResolv which in
turn would remove the lookup/query what we are trying to access after
the callback is returned.
So it is enough to remove the lookup or query entry from queue before
cb is called and then manually remove it after the callback has returned.
|
|
The lookup must be removed from lookup queue and not from query
queue when cancelling the lookup. Otherwise it is possible that
we might access an already removed lookup that is still found in
lookup queue.
Fixes BMC#25728
|
|
When the callback has been called, the whole structure might be
freed. Thus don't call the debug function tied to the structure.
|
|
Use predefined mnemonics from arpa/nameserv.h for the return value from
ns_msg_getflag rather than magic numbers.
|
|
When performing a resolver lookup from timeserver or wpad, both perform
queries with an unspecified address family. This means that both A and
AAAA record queries are issued. In cases where a valid, successful A
response comes back but where the AAAA query results in a timeout, do
not smash the successful A status with the time out AAAA status;
otherwise, the timeserver or wpad will appear to fail to them when, in
fact, the A query was successful and more than satisfies its unspecified
address family requirement.
Partial fix for BMC#25486.
|
|
In both parse_response and query_timeout there exists logic that checks
to ensure that both an A and AAAA lookups have either been responded to
or timed out before processing and returning results to the caller. In
query_timeout, there was a typo in the condition check such that it did
not match those conditions tested in parse_response.
|
|
|
|
|
|
|
|
|
|
Define GWebRouteFunc that will be called when a route to the
intended destination may need to be set up.
|
|
According to gnutls/compat.h, gnutls_session typedef was deprecated
since 2.x in favor of gnutls_session_t. Use the new typedef then.
|
|
These prints are useful when checking why network
connection failed.
|
|
Setting socket option BINDTODEVICE requires CAP_NET_RAW capability.
|
|
|
|
Fix null pointer derefencing in "free_session" and
"process_send_buffer" functions
|
|
|
|
|
|
|
|
g_atomic_int_exchange_and_add() has been removed from glib 2.30
and g_atomic_int_add() should be used. Though there are still
quite a few distros out which do not ship a glib version with
g_atomic_int_add().
Instead of maintaing a compatiblilty glib layer we just use
the built-in functions for atomic memory access.
|
|
Make sure all file descriptor are closed.
|
|
Make buf just big enough and initialize it in order to get
rid of valgrind error (accessing uninitialized memory).
|
|
|
|
|
|
Adding the capability to restrict DNS queries to a specific address family
through gresolv_set_address_family(). By default, AF_UNSPEC is applied.
|
|
This priority string will only enable SSL 3.0 and TLS 1.0 as protocols
and will disable, via the %COMPAT keyword, several TLS protocol options
that are known to cause compatibility problems.
Reference: http://www.gnu.org/software/gnutls/manual/html_node/Interoperability.html#Interoperability
|
|
If we use gnutls 2.12.0 or later it's necessary to call
gnutls_transport_set_lowat() to disable the lowat functionality. Since
this function is deprecated in new versions of gnutls, call it only if
using an older version.
|
|
family.
|
|
|
|
|