Commit Graph

223 Commits

Author SHA1 Message Date
Michael Davidsaver
dfeb9fd5a5 more Troubleshoot "no more data in UDP packet" 2019-05-21 08:51:00 -07:00
Michael Davidsaver
ecee708d3a redo hexDump
ludicrously inefficient (cf. toHex() ), and inflexible.
2019-05-21 08:51:00 -07:00
Michael Davidsaver
0084b6e60a de-virt Transport::getRevision()
Makes clear that this is/was only for TCP,
and eliminate redundant storage.  Also apply
locking to this storage.

Use header version directly in search handler.
Correct as only UDP search is actually used atm.
2019-05-20 17:48:10 -07:00
Michael Davidsaver
32ba2f32d0 avoid deprecated ByteBuffer::getArray()
use identical, but not overloaded, getBuffer()
2019-05-19 14:09:38 -07:00
Michael Davidsaver
736e0c169a Merge branch 'auth'
* auth:
  fix osdGetRoles
  oops
  Add showauth executable
  getgrouplist() on OSX has different sig.
  auth fix mingw static
  fix search PeerInfo
  PeerInfo in pva/server.h and pva/sharedstate.h
  make PeerInfo available during search phase
  auth status void accidental success.
  minor doc
  always need to link with netapi32 now
  authorize with local group lookup
  Add osdGetRoles()
  authorization framework
  pvasr show PeerInfo
  redo security (aka. access control)
  remove asCheck

# Conflicts:
#	src/server/pv/responseHandlers.h
#	src/server/responseHandlers.cpp
2019-05-12 14:40:29 -07:00
Michael Davidsaver
3fa1e83b55 avoid redundant sockaddr -> string 2019-04-17 09:35:43 -07:00
Michael Davidsaver
22622e91a9 server: detect duplicate channelCreated() calls 2019-02-19 19:58:13 -08:00
Michael Davidsaver
d52d8cf5d4 pva/server.h allow createChannel() to return NULL 2019-02-19 19:55:58 -08:00
Michael Davidsaver
c5fe16eff2 fix search PeerInfo 2019-02-19 19:54:42 -08:00
Michael Davidsaver
34f53c123a PeerInfo in pva/server.h and pva/sharedstate.h 2019-01-29 19:59:53 -08:00
Michael Davidsaver
d8f9ef2557 make PeerInfo available during search phase 2019-01-29 19:59:53 -08:00
Michael Davidsaver
b46e0972ea minor doc 2019-01-13 19:04:59 -08:00
Michael Davidsaver
9babc06ab3 pvasr show PeerInfo 2019-01-12 15:14:19 -08:00
Michael Davidsaver
fa484a883a redo security (aka. access control)
Break up monolithic SecurityPlugin API into three parts.

1. Authentication.
2. Authorization.
3. Access Control decision.  Left to ChannelProviders
2019-01-12 15:14:19 -08:00
Michael Davidsaver
13cac5f4cc remove asCheck
This interface will be removed.
2019-01-12 14:31:19 -08:00
Michael Davidsaver
f84774e3ec PVA server earlier check of monitor window
Check window size before attemting poll() as apparently
"spurious" send() is possible.
2018-10-22 14:07:22 -07:00
Michael Davidsaver
3f85f7c2ad cleanup 2018-10-22 10:04:57 -07:00
Michael Davidsaver
a486f3d4c7 SharedPV::Handler better defaults 2018-10-18 17:52:56 -07:00
Michael Davidsaver
31ed0b55ec minor 2018-10-18 17:52:56 -07:00
Michael Davidsaver
729f16f94e SharedPV move internal names under detail:: 2018-10-18 17:52:35 -07:00
Michael Davidsaver
0a5f8b44db doc 2018-10-18 15:18:00 -07:00
Michael Davidsaver
ac9ebc47ba improper use of rand() w/o RAND_MAX
... with an extra dose of integer modulo thrown in.
2018-10-18 15:18:00 -07:00
Michael Davidsaver
9de8676a6f pvlist debugging 2018-10-18 15:18:00 -07:00
Michael Davidsaver
731767b086 SharedPV fix onFirstConnect() on monitor creation 2018-10-08 07:10:13 -07:00
Michael Davidsaver
9ca7487e29 SharedPV allow use of Channel::destroy() to trigger onLastDisconnect()
Add dead flag to catch double destroy() or use after destroy()
2018-10-07 20:07:40 -07:00
Michael Davidsaver
ed1bd1b962 SharedPV defer onFirstConnect() to first getField/Put/Monitor 2018-10-07 20:07:40 -07:00
Michael Davidsaver
53b95dd336 more SharedPV rpc state tracking
handle re-open() with RPC
2018-10-06 17:55:57 -07:00
Michael Davidsaver
605c172d3c fix SharedPV allow rpc() while close()'d
Don't call channelRPCConnect() again during open().

Turns out that a second channelRPCConnect() has
the effect of sending a reply with OK and NULL.
2018-10-04 07:31:01 -07:00
Michael Davidsaver
542d51a215 RPC troubleshooting
something funny is going on
2018-10-03 23:41:30 -07:00
Michael Davidsaver
421d50e3ba SharedPV too many notifiedConn
notifiedConn set more often than it should.
2018-10-03 18:36:32 -07:00
Michael Davidsaver
2fec84461d use of CMD_* instead of magic numbers 2018-10-02 12:52:24 -07:00
Michael Davidsaver
4e5aef3e42 SharedPV allow rpc() while close()'d
No reason to prevent this as RPCs need not use
the same type (Structure) as get/put/monitor.
2018-10-02 12:52:24 -07:00
Michael Davidsaver
4296c5e015 more SharedPV::close() 2018-09-27 13:56:13 -07:00
Michael Davidsaver
83b2105241 StaticProvider createChannel() avoid possible deadlock
connect() may invoke SharedPV onFirstConnect() callback.
2018-09-26 16:38:22 -07:00
Michael Davidsaver
7ed6f1315f SharedPV::open() less work under lock 2018-09-26 10:31:33 -07:00
Michael Davidsaver
6b463d77e1 SharedPV ensure callback pairing
Ensure that onLastDisconnect() isn't called
unless onFirstConnect() is/has been called.
2018-09-21 11:35:57 -07:00
Michael Davidsaver
a6eca51fa0 StaticProvider dtor close() with destroy=true 2018-09-21 11:35:57 -07:00
Michael Davidsaver
293dd3c2e9 sharedpv simplify logic
duh... always empty() after clear()
2018-09-21 11:35:57 -07:00
Michael Davidsaver
52e0bd09f8 sharedpv: defend against dying objects in SharedPV::close()
Likely when destroy=true
2018-09-21 11:35:57 -07:00
Michael Davidsaver
5f03fafba7 sharedstate minor doc 2018-09-21 11:35:57 -07:00
Michael Davidsaver
3bc1603f47 SharedPV.close() call onLastDisconnect()
ensure that onLastDisconnect() is called when
the channels list becomes empty (edge), and
not afterwards.
2018-09-21 11:35:57 -07:00
Michael Davidsaver
9ec0172520 sharedstate: close() from dtor 2018-09-21 11:35:57 -07:00
Michael Davidsaver
dd1e2b4048 sharedstate handle compute() error internally 2018-09-21 11:35:57 -07:00
Michael Davidsaver
643f7e47c8 Apply PVRequestMapper to shared state put/get 2018-09-21 11:35:57 -07:00
Michael Davidsaver
8b60d87e42 pvac fix MailboxHandler
This is why OVERRIDE is so important...
2018-07-31 18:48:23 -07:00
Michael Davidsaver
f39174cb74 StaticProvider need to expose iterator type 2018-07-17 20:42:21 -07:00
Michael Davidsaver
f4b245710d sharedstate: Get use pvRequest field selection mask 2018-07-14 15:00:15 -07:00
Michael Davidsaver
bf8b0bde16 quiet warning 2018-07-14 13:58:00 -07:00
Michael Davidsaver
e29cda2a74 sharedstate: missed a reftrack 2018-07-11 18:14:54 -07:00
Michael Davidsaver
1a459d75d5 dllimport/export part 4 2018-07-06 16:00:33 -07:00