I found weired situation on plgd coap-gateway.
Registration of device does not work properly and does not save access token, refresh token on user devices table.
When I tried to register device, Post /oic/sec/account send proper response with access token, refresh token, uid at first but in a row, it sends error response to device about invalid authorization code. I think there seems to be some logic to exchange token twice in a request of sign up.
More over, access token and refresh token was not saved in user devices table on mongo db after using latest plgd open source (commit 0f2c187).
2021-08-13 02:14:44 | 2021-08-12T17:14:44.161Z DEBUG log/log.go:83
-- | --
| | 2021-08-13 02:14:44 | -------------------RECEIVED-COMMAND------------------
| | 2021-08-13 02:14:44 | DeviceId: unknown(10.1.2.223:54490)
| | 2021-08-13 02:14:44 | Token: 860f28cdf0f3c0d6
| | 2021-08-13 02:14:44 | Path: oic/sec/account
| | 2021-08-13 02:14:44 | Code: POST
| | 2021-08-13 02:14:44 | Query: []
| | 2021-08-13 02:14:44 | ContentFormat: application/vnd.ocf+cbor
| | 2021-08-13 02:14:44 | CBOR:
| | 2021-08-13 02:14:44 | {"accesstoken":"bJ4ywwOl9Kv-r_mI","authprovider":"auth0","devicetype":"device","di":"6ec91ff4-60e9-47db-6257-3f05c6867e10"}
| | 2021-08-13 02:14:44 | 2021-08-12T17:14:44.651Z DEBUG log/log.go:83
| | 2021-08-13 02:14:44 | -------------------RECEIVED-COMMAND------------------
| | 2021-08-13 02:14:44 | DeviceId: unknown(10.1.2.223:54490)
| | 2021-08-13 02:14:44 | Token: 7c8f474fa0db85e3
| | 2021-08-13 02:14:44 | Path: oic/sec/account
| | 2021-08-13 02:14:44 | Code: POST
| | 2021-08-13 02:14:44 | Query: []
| | 2021-08-13 02:14:44 | ContentFormat: application/vnd.ocf+cbor
| | 2021-08-13 02:14:44 | CBOR:
| | 2021-08-13 02:14:44 | {"accesstoken":"bJ4ywwOl9Kv-r_mI","authprovider":"auth0","devicetype":"device","di":"6ec91ff4-60e9-47db-6257-3f05c6867e10"}
| | 2021-08-13 02:14:44 | 2021-08-12T17:14:44.989Z INFO zap/options.go:212 finished unary call with code OK {"grpc.start_time": "2021-08-12T17:14:44Z", "system": "grpc", "span.kind": "server", "grpc.service": "ocf.cloud.auth.pb.AuthorizationService", "grpc.method": "AddDevice", "peer.address": "10.1.3.0:34394", "grpc.code": "OK", "grpc.time_ms": 6.389999866485596}
| | 2021-08-13 02:14:44 | 2021-08-12T17:14:44.992Z DEBUG log/log.go:83
| | 2021-08-13 02:14:44 | -------------------SEND-RESPONSE------------------
| | 2021-08-13 02:14:44 | DeviceId: unknown(10.1.2.223:54490)
| | 2021-08-13 02:14:44 | Token: 860f28cdf0f3c0d6
| | 2021-08-13 02:14:44 | Path:
| | 2021-08-13 02:14:44 | Code: Changed
| | 2021-08-13 02:14:44 | Query: []
| | 2021-08-13 02:14:44 | ContentFormat: application/vnd.ocf+cbor
| | 2021-08-13 02:14:44 | CBOR:
| | 2021-08-13 02:14:44 | {"accesstoken":"eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCIsImtpZCI6ImhPeHdxSzJCM2k5amZjSFo4dVh6QyJ9.eyJodHRwczovL3d3dy5vY2ZjbG91ZC5jb20vdGVuYW50IjoiKiIsImlzcyI6Imh0dHBzOi8vdHJpc2hpYTEyOTguYXV0aDAuY29tLyIsInN1YiI6ImF1dGgwfDYxMTI0NjdmM2E4M2E4MDA3MGJjNjk5ZCIsImF1ZCI6Imh0dHBzOi8vd3d3Lm9jZmNsb3VkLmNvbSIsImlhdCI6MTYyODc4ODQ2NCwiZXhwIjoxNjI4ODc0ODY0LCJhenAiOiJEZ2V6THlXczFoSFJmNjkxNHRreVVkcDRRRG1rVm1ueiIsInNjb3BlIjoicjpkZXZpY2VpbmZvcm1hdGlvbjoqIHI6cmVzb3VyY2VzOiogdzpyZXNvdXJjZXM6KiB3OnN1YnNjcmlwdGlvbnM6KiBvZmZsaW5lX2FjY2VzcyJ9.zZqbbNpyc2tbwVr2jCEs9MjyajvL06A0da0CirJdAfsiR3fMPSdAsz7F39hkskSIjN1xSYY7KRl4NDDli5EABKHnSeXGOUnA0NCV1ILgLA8J-F0gwq_kYyVwJQ5oQ6L97nO2uZ5RpXxqkmQ8jBdTdR9_aD2dNccLRxxHxqbNN7ZomkgRJC13RhRv_SY2oZdxw8GjBOZQt3cs-PdQKJP0P0ZOWSx8l_ftAXniHZxS8JltmyBtYjWHfe-KMrAOCT6WceLqgO1ctnAPF0hK_1cSP7CetKNxkL55zG7jq-d1mbp7V_5uQIJcYUrz85xuWswIEJF135oT0oq5kd1J1iDTlw","expiresin":86399,"redirecturi":"","refreshtoken":"v1.MXnl0zc_bmZtpRJfIA1GeylefPnaenUaWvZY-sqOqLwjhSYRtXmBFz-9R18fnChVZYDETv35j57QjWb3EX2-WvM","uid":"auth0\|6112467f3a83a80070bc699d"}
| | 2021-08-13 02:14:45 | 2021-08-12T17:14:45.061Z ERROR log/log.go:98 cannot handle sign up: oauth2: cannot fetch token: 403 Forbidden
| | 2021-08-13 02:14:45 | Response: {"error":"invalid_grant","error_description":"Invalid authorization code"}
| | 2021-08-13 02:14:45 | github.com/plgd-dev/cloud/pkg/log.Error
| | 2021-08-13 02:14:45 | /go/src/github.com/plgd-dev/cloud/pkg/log/log.go:98
| | 2021-08-13 02:14:45 | github.com/plgd-dev/cloud/pkg/log.LogAndReturnError
| | 2021-08-13 02:14:45 | /go/src/github.com/plgd-dev/cloud/pkg/log/logAndReturnError.go:35
| | 2021-08-13 02:14:45 | github.com/plgd-dev/cloud/pkg/log.Errorf
| | 2021-08-13 02:14:45 | /go/src/github.com/plgd-dev/cloud/pkg/log/log.go:124
| | 2021-08-13 02:14:45 | github.com/plgd-dev/cloud/coap-gateway/service.(*Client).logAndWriteErrorResponse
| | 2021-08-13 02:14:45 | /go/src/github.com/plgd-dev/cloud/coap-gateway/service/clientLogAndWriteErrorResponse.go:36
| | 2021-08-13 02:14:45 | github.com/plgd-dev/cloud/coap-gateway/service.signUpPostHandler.func1
| | 2021-08-13 02:14:45 | /go/src/github.com/plgd-dev/cloud/coap-gateway/service/signUp.go:72
| | 2021-08-13 02:14:45 | github.com/plgd-dev/cloud/coap-gateway/service.signUpPostHandler
| | 2021-08-13 02:14:45 | /go/src/github.com/plgd-dev/cloud/coap-gateway/service/signUp.go:94
| | 2021-08-13 02:14:45 | github.com/plgd-dev/cloud/coap-gateway/service.signUpHandler
| | 2021-08-13 02:14:45 | /go/src/github.com/plgd-dev/cloud/coap-gateway/service/signUp.go:127
| | 2021-08-13 02:14:45 | github.com/plgd-dev/cloud/coap-gateway/service.validateCommand.func1
| | 2021-08-13 02:14:45 | /go/src/github.com/plgd-dev/cloud/coap-gateway/service/service.go:290
| | 2021-08-13 02:14:45 | github.com/plgd-dev/cloud/pkg/sync/task/queue.(*Queue).Submit.func1
| | 2021-08-13 02:14:45 | /go/src/github.com/plgd-dev/cloud/pkg/sync/task/queue/queue.go:68
| | 2021-08-13 02:14:45 | github.com/panjf2000/ants/v2.(*goWorker).run.func1
| | 2021-08-13 02:14:45 | /go/pkg/mod/github.com/panjf2000/ants/[email protected]/worker.go:70
| | 2021-08-13 02:14:45 | 2021-08-12T17:14:45.066Z DEBUG log/log.go:83
| | 2021-08-13 02:14:45 | -------------------SEND-ERROR------------------
| | 2021-08-13 02:14:45 | DeviceId: unknown(10.1.2.223:54490)
| | 2021-08-13 02:14:45 | Token: 7c8f474fa0db85e3
| | 2021-08-13 02:14:45 | Path:
| | 2021-08-13 02:14:45 | Code: Unauthorized
| | 2021-08-13 02:14:45 | Query: []
| | 2021-08-13 02:14:45 | error Message:
| | 2021-08-13 02:14:45 | cannot handle sign up: oauth2: cannot fetch token: 403 Forbidden
| | 2021-08-13 02:14:45 | Response: {"error":"invalid_grant","error_description":"Invalid authorization code"}
| | 2021-08-13 02:14:45 | 2021-08-12T17:14:45.461Z INFO zap/options.go:212 finished streaming call with code OK {"grpc.start_time": "2021-08-12T17:14:45Z", "grpc.request.deadline": "2021-08-12T17:15:00Z", "system": "grpc", "span.kind": "server", "grpc.service": "ocf.cloud.auth.pb.AuthorizationService", "grpc.method": "GetUserDevices", "peer.address": "10.1.2.248:43570", "grpc.code": "OK", "grpc.time_ms": 7.1020002365112305}
| | 2021-08-13 02:14:46 | 2021-08-12T17:14:46.032Z DEBUG log/log.go:83
| | 2021-08-13 02:14:46 | -------------------RECEIVED-COMMAND------------------
| | 2021-08-13 02:14:46 | DeviceId: unknown(10.1.2.223:54490)
| | 2021-08-13 02:14:46 | Token: ed9734cfe02f335b
| | 2021-08-13 02:14:46 | Path: oic/sec/session
| | 2021-08-13 02:14:46 | Code: POST
| | 2021-08-13 02:14:46 | Query: []
| | 2021-08-13 02:14:46 | ContentFormat: application/vnd.ocf+cbor
| | 2021-08-13 02:14:46 | CBOR:
| | 2021-08-13 02:14:46 | {"accesstoken":"eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCIsImtpZCI6ImhPeHdxSzJCM2k5amZjSFo4dVh6QyJ9.eyJodHRwczovL3d3dy5vY2ZjbG91ZC5jb20vdGVuYW50IjoiKiIsImlzcyI6Imh0dHBzOi8vdHJpc2hpYTEyOTguYXV0aDAuY29tLyIsInN1YiI6ImF1dGgwfDYxMTI0NjdmM2E4M2E4MDA3MGJjNjk5ZCIsImF1ZCI6Imh0dHBzOi8vd3d3Lm9jZmNsb3VkLmNvbSIsImlhdCI6MTYyODc4ODQ2NCwiZXhwIjoxNjI4ODc0ODY0LCJhenAiOiJEZ2V6THlXczFoSFJmNjkxNHRreVVkcDRRRG1rVm1ueiIsInNjb3BlIjoicjpkZXZpY2VpbmZvcm1hdGlvbjoqIHI6cmVzb3VyY2VzOiogdzpyZXNvdXJjZXM6KiB3OnN1YnNjcmlwdGlvbnM6KiBvZmZsaW5lX2FjY2VzcyJ9.zZqbbNpyc2tbwVr2jCEs9MjyajvL06A0da0CirJdAfsiR3fMPSdAsz7F39hkskSIjN1xSYY7KRl4NDDli5EABKHnSeXGOUnA0NCV1ILgLA8J-F0gwq_kYyVwJQ5oQ6L97nO2uZ5RpXxqkmQ8jBdTdR9_aD2dNccLRxxHxqbNN7ZomkgRJC13RhRv_SY2oZdxw8GjBOZQt3cs-PdQKJP0P0ZOWSx8l_ftAXniHZxS8JltmyBtYjWHfe-KMrAOCT6WceLqgO1ctnAPF0hK_1cSP7CetKNxkL55zG7jq-d1mbp7V_5uQIJcYUrz85xuWswIEJF135oT0oq5kd1J1iDTlw","di":"6ec91ff4-60e9-47db-6257-3f05c6867e10","login":true,"uid":"auth0\|6112467f3a83a80070bc699d"}
| | 2021-08-13 02:14:46 | 2021-08-12T17:14:46.032Z DEBUG log/log.go:108 close client 10.1.2.223:54490 for device
| | 2021-08-13 02:14:46 | 2021-08-12T17:14:46.033Z DEBUG log/log.go:108 cleanUp client 10.1.2.223:54490 for device
| | 2021-08-13 02:14:46 | 2021-08-12T17:14:46.033Z DEBUG log/log.go:108 Authorization context replaced for client 10.1.2.223:54490, device , user
| | 2021-08-13 02:14:46 | 2021-08-12T17:14:46.037Z DEBUG log/log.go:108 Authorization context replaced for client 10.1.2.223:54490, device 6ec91ff4-60e9-47db-6257-3f05c6867e10, user auth0\|6112467f3a83a80070bc699d
| | 2021-08-13 02:14:46 | 2021-08-12T17:14:46.037Z DEBUG log/log.go:108 temporary error: cannot handle sign in: cannot update cloud device status: rpc error: code = Canceled desc = context canceled
| | 2021-08-13 02:14:46 | 2021-08-12T17:14:46.039Z DEBUG log/log.go:108 cannot send error to 6ec91ff4-60e9-47db-6257-3f05c6867e10: cannot write to connection: context canceled
| | 2021-08-13 02:14:46 | 2021-08-12T17:14:46.039Z DEBUG log/log.go:83
| | 2021-08-13 02:14:46 | -------------------SEND-ERROR------------------
| | 2021-08-13 02:14:46 | DeviceId: 6ec91ff4-60e9-47db-6257-3f05c6867e10
| | 2021-08-13 02:14:46 | Token: ed9734cfe02f335b
| | 2021-08-13 02:14:46 | Path:
| | 2021-08-13 02:14:46 | Code: ServiceUnavailable
| | 2021-08-13 02:14:46 | Query: []
| | 2021-08-13 02:14:46 | error Message:
| | 2021-08-13 02:14:46 | temporary error: cannot handle sign in: cannot update cloud device status: rpc error: code = Canceled desc = context canceled
| | 2021-08-13 02:14:51 | 2021-08-12T17:14:51.402Z INFO zap/options.go:212 finished streaming call with code OK {"grpc.start_time": "2021-08-12T17:14:51Z", "grpc.request.deadline": "2021-08-12T17:15:06Z", "system": "grpc", "span.kind": "server", "grpc.service": "ocf.cloud.auth.pb.AuthorizationService", "grpc.method": "GetUserDevices", "peer.address": "10.1.2.249:60340", "grpc.code": "OK", "grpc.time_ms": 1.9819999933242798}
| | 2021-08-13 02:14:51 | 2021-08-12T17:14:51.645Z DEBUG log/log.go:83
| | 2021-08-13 02:14:51 | -------------------RECEIVED-COMMAND------------------
| | 2021-08-13 02:14:51 | DeviceId: unknown(10.1.2.223:54580)
| | 2021-08-13 02:14:51 | Token: 9d37c28ee1a53eb2
| | 2021-08-13 02:14:51 | Path: oic/sec/tokenrefresh
| | 2021-08-13 02:14:51 | Code: POST
| | 2021-08-13 02:14:51 | Query: []
| | 2021-08-13 02:14:51 | ContentFormat: application/vnd.ocf+cbor
| | 2021-08-13 02:14:51 | CBOR:
| | 2021-08-13 02:14:51 | {"di":"6ec91ff4-60e9-47db-6257-3f05c6867e10","granttype":"refresh_token","refreshtoken":"v1.MXnl0zc_bmZtpRJfIA1GeylefPnaenUaWvZY-sqOqLwjhSYRtXmBFz-9R18fnChVZYDETv35j57QjWb3EX2-WvM","uid":"auth0\|6112467f3a83a80070bc699d"}
| | 2021-08-13 02:14:52 | 2021-08-12T17:14:52.137Z DEBUG log/log.go:83
| | 2021-08-13 02:14:52 | -------------------RECEIVED-COMMAND------------------
| | 2021-08-13 02:14:52 | DeviceId: unknown(10.1.2.223:54580)
| | 2021-08-13 02:14:52 | Token: 255fc8ea50c9d196
| | 2021-08-13 02:14:52 | Path: oic/sec/tokenrefresh
| | 2021-08-13 02:14:52 | Code: POST
| | 2021-08-13 02:14:52 | Query: []
| | 2021-08-13 02:14:52 | ContentFormat: application/vnd.ocf+cbor
| | 2021-08-13 02:14:52 | CBOR:
| | 2021-08-13 02:14:52 | {"di":"6ec91ff4-60e9-47db-6257-3f05c6867e10","granttype":"refresh_token","refreshtoken":"v1.MXnl0zc_bmZtpRJfIA1GeylefPnaenUaWvZY-sqOqLwjhSYRtXmBFz-9R18fnChVZYDETv35j57QjWb3EX2-WvM","uid":"auth0\|6112467f3a83a80070bc699d"}
| | 2021-08-13 02:14:52 | 2021-08-12T17:14:52.149Z DEBUG log/log.go:83
| | 2021-08-13 02:14:52 | -------------------SEND-RESPONSE------------------
| | 2021-08-13 02:14:52 | DeviceId: unknown(10.1.2.223:54580)
| | 2021-08-13 02:14:52 | Token: 9d37c28ee1a53eb2
| | 2021-08-13 02:14:52 | Path:
| | 2021-08-13 02:14:52 | Code: Changed
| | 2021-08-13 02:14:52 | Query: []
| | 2021-08-13 02:14:52 | ContentFormat: application/vnd.ocf+cbor
| | 2021-08-13 02:14:52 | CBOR:
| | 2021-08-13 02:14:52 | {"accesstoken":"eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCIsImtpZCI6ImhPeHdxSzJCM2k5amZjSFo4dVh6QyJ9.eyJodHRwczovL3d3dy5vY2ZjbG91ZC5jb20vdGVuYW50IjoiKiIsImlzcyI6Imh0dHBzOi8vdHJpc2hpYTEyOTguYXV0aDAuY29tLyIsInN1YiI6ImF1dGgwfDYxMTI0NjdmM2E4M2E4MDA3MGJjNjk5ZCIsImF1ZCI6Imh0dHBzOi8vd3d3Lm9jZmNsb3VkLmNvbSIsImlhdCI6MTYyODc4ODQ3MSwiZXhwIjoxNjI4ODc0ODcxLCJhenAiOiJEZ2V6THlXczFoSFJmNjkxNHRreVVkcDRRRG1rVm1ueiIsInNjb3BlIjoicjpkZXZpY2VpbmZvcm1hdGlvbjoqIHI6cmVzb3VyY2VzOiogdzpyZXNvdXJjZXM6KiB3OnN1YnNjcmlwdGlvbnM6KiBvZmZsaW5lX2FjY2VzcyJ9.vYrpnKLzxx0kurIZd3VI8fu93Tb5LyP85H8iDQtYkhuGwVNi-nmFr_h0GQoucssIvFkjEsKi9_HYVtO2duhlLAWpiFHqfV24NqymynpllUCAETicdtg6_OV1j4G02GRefPL-wN1EGHutHnG2h8UMxfphwA70PgO29eVmz49EXPJMsbj7l8DfhFvBPOEOfyXgYq-_JDVO52JTFeq1lK7CC53OM76TA2wIkdt5wSDKY5NT3vbiO47Sda0vz86d-LcGCkbUg3_iyPV5NeupFLGKASk1QwfiT9bG4rCHpPJs3a9Pomrn3xw88AtTeXmSLc6dCr2gutP4KP85qM3alPGMzQ","expiresin":86399,"refreshtoken":"v1.Mnnl0zc_bmZtpRJfIA1Geyma8mI209786Qy-cGMyBXBK9Dxn7LML3pIEmrmUsieI5Ah2s5wXZS1HxWgIgybmDtg"}
| | 2021-08-13 02:14:52 | 2021-08-12T17:14:52.804Z DEBUG log/log.go:83
| | 2021-08-13 02:14:52 | -------------------SEND-RESPONSE------------------
| | 2021-08-13 02:14:52 | DeviceId: unknown(10.1.2.223:54580)
| | 2021-08-13 02:14:52 | Token: 255fc8ea50c9d196
| | 2021-08-13 02:14:52 | Path:
| | 2021-08-13 02:14:52 | Code: Changed
| | 2021-08-13 02:14:52 | Query: []
| | 2021-08-13 02:14:52 | ContentFormat: application/vnd.ocf+cbor
| | 2021-08-13 02:14:52 | CBOR:
| | 2021-08-13 02:14:52 | {"accesstoken":"eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCIsImtpZCI6ImhPeHdxSzJCM2k5amZjSFo4dVh6QyJ9.eyJodHRwczovL3d3dy5vY2ZjbG91ZC5jb20vdGVuYW50IjoiKiIsImlzcyI6Imh0dHBzOi8vdHJpc2hpYTEyOTguYXV0aDAuY29tLyIsInN1YiI6ImF1dGgwfDYxMTI0NjdmM2E4M2E4MDA3MGJjNjk5ZCIsImF1ZCI6Imh0dHBzOi8vd3d3Lm9jZmNsb3VkLmNvbSIsImlhdCI6MTYyODc4ODQ3MSwiZXhwIjoxNjI4ODc0ODcxLCJhenAiOiJEZ2V6THlXczFoSFJmNjkxNHRreVVkcDRRRG1rVm1ueiIsInNjb3BlIjoicjpkZXZpY2VpbmZvcm1hdGlvbjoqIHI6cmVzb3VyY2VzOiogdzpyZXNvdXJjZXM6KiB3OnN1YnNjcmlwdGlvbnM6KiBvZmZsaW5lX2FjY2VzcyJ9.vYrpnKLzxx0kurIZd3VI8fu93Tb5LyP85H8iDQtYkhuGwVNi-nmFr_h0GQoucssIvFkjEsKi9_HYVtO2duhlLAWpiFHqfV24NqymynpllUCAETicdtg6_OV1j4G02GRefPL-wN1EGHutHnG2h8UMxfphwA70PgO29eVmz49EXPJMsbj7l8DfhFvBPOEOfyXgYq-_JDVO52JTFeq1lK7CC53OM76TA2wIkdt5wSDKY5NT3vbiO47Sda0vz86d-LcGCkbUg3_iyPV5NeupFLGKASk1QwfiT9bG4rCHpPJs3a9Pomrn3xw88AtTeXmSLc6dCr2gutP4KP85qM3alPGMzQ","expiresin":86399,"refreshtoken":"v1.Mnnl0zc_bmZtpRJfIA1GeyktJqLcGHiPt9sdaDV_OQE0mrblhtlJa6-SRlGFfsLgkNWMLcmrIP237l0Xd-L0Hps"}
| | 2021-08-13 02:14:55 | 2021-08-12T17:14:55.218Z DEBUG log/log.go:83
| | 2021-08-13 02:14:55 | -------------------RECEIVED-COMMAND------------------
| | 2021-08-13 02:14:55 | DeviceId: unknown(10.1.2.223:54580)
| | 2021-08-13 02:14:55 | Token: 2a9c76708d96ff7f
| | 2021-08-13 02:14:55 | Path: oic/sec/session
| | 2021-08-13 02:14:55 | Code: POST
| | 2021-08-13 02:14:55 | Query: []
| | 2021-08-13 02:14:55 | ContentFormat: application/vnd.ocf+cbor
| | 2021-08-13 02:14:55 | CBOR:
| | 2021-08-13 02:14:55 | {"accesstoken":"eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCIsImtpZCI6ImhPeHdxSzJCM2k5amZjSFo4dVh6QyJ9.eyJodHRwczovL3d3dy5vY2ZjbG91ZC5jb20vdGVuYW50IjoiKiIsImlzcyI6Imh0dHBzOi8vdHJpc2hpYTEyOTguYXV0aDAuY29tLyIsInN1YiI6ImF1dGgwfDYxMTI0NjdmM2E4M2E4MDA3MGJjNjk5ZCIsImF1ZCI6Imh0dHBzOi8vd3d3Lm9jZmNsb3VkLmNvbSIsImlhdCI6MTYyODc4ODQ3MSwiZXhwIjoxNjI4ODc0ODcxLCJhenAiOiJEZ2V6THlXczFoSFJmNjkxNHRreVVkcDRRRG1rVm1ueiIsInNjb3BlIjoicjpkZXZpY2VpbmZvcm1hdGlvbjoqIHI6cmVzb3VyY2VzOiogdzpyZXNvdXJjZXM6KiB3OnN1YnNjcmlwdGlvbnM6KiBvZmZsaW5lX2FjY2VzcyJ9.vYrpnKLzxx0kurIZd3VI8fu93Tb5LyP85H8iDQtYkhuGwVNi-nmFr_h0GQoucssIvFkjEsKi9_HYVtO2duhlLAWpiFHqfV24NqymynpllUCAETicdtg6_OV1j4G02GRefPL-wN1EGHutHnG2h8UMxfphwA70PgO29eVmz49EXPJMsbj7l8DfhFvBPOEOfyXgYq-_JDVO52JTFeq1lK7CC53OM76TA2wIkdt5wSDKY5NT3vbiO47Sda0vz86d-LcGCkbUg3_iyPV5NeupFLGKASk1QwfiT9bG4rCHpPJs3a9Pomrn3xw88AtTeXmSLc6dCr2gutP4KP85qM3alPGMzQ","di":"6ec91ff4-60e9-47db-6257-3f05c6867e10","login":true,"uid":"auth0\|6112467f3a83a80070bc699d"}
| | 2021-08-13 02:14:55 | 2021-08-12T17:14:55.219Z DEBUG log/log.go:108 Authorization context replaced for client 10.1.2.223:54580, device 6ec91ff4-60e9-47db-6257-3f05c6867e10, user auth0\|6112467f3a83a80070bc699d
| | 2021-08-13 02:14:55 | 2021-08-12T17:14:55.373Z DEBUG log/log.go:83
| | 2021-08-13 02:14:55 | -------------------SEND-RESPONSE------------------
| | 2021-08-13 02:14:55 | DeviceId: 6ec91ff4-60e9-47db-6257-3f05c6867e10
| | 2021-08-13 02:14:55 | Token: 2a9c76708d96ff7f
| | 2021-08-13 02:14:55 | Path:
| | 2021-08-13 02:14:55 | Code: Changed
| | 2021-08-13 02:14:55 | Query: []
| | 2021-08-13 02:14:55 | ContentFormat: application/vnd.ocf+cbor
| | 2021-08-13 02:14:55 | CBOR:
| | 2021-08-13 02:14:55 | {"expiresin":86375}
| | 2021-08-13 02:14:55 | 2021-08-12T17:14:55.394Z DEBUG log/log.go:83
| | 2021-08-13 02:14:55 | -------------------RECEIVED-COMMAND------------------
| | 2021-08-13 02:14:55 | DeviceId: 6ec91ff4-60e9-47db-6257-3f05c6867e10
| | 2021-08-13 02:14:55 | Token: 013a4230a1a5b18f
| | 2021-08-13 02:14:55 | Path: oic/rd
| | 2021-08-13 02:14:55 | Code: POST
| | 2021-08-13 02:14:55 | Query: [rt=oic.wk.rdpub]
| | 2021-08-13 02:14:55 | ContentFormat: application/vnd.ocf+cbor
| | 2021-08-13 02:14:55 | CBOR:
| | 2021-08-13 02:14:55 | {"di":"6ec91ff4-60e9-47db-6257-3f05c6867e10","links":[{"href":"/oic/p","if":["oic.if.r","oic.if.baseline"],"ins":564140495,"p":{"bm":3},"rel":"hosts","rt":["oic.wk.p"]},{"href":"/oic/d","if":["oic.if.r","oic.if.baseline"],"ins":3110858707,"p":{"bm":3},"rel":"hosts","rt":["oic.d.smartplug","oic.wk.d"]},{"href":"/plug/1","if":["oic.if.a","oic.if.baseline"],"ins":3159645952,"p":{"bm":3},"rel":"hosts","rt":["oic.r.switch.binary"]},{"href":"/switches","if":["oic.if.ll","oic.if.create","oic.if.b","oic.if.baseline"],"ins":2934548123,"p":{"bm":3},"rel":"hosts","rt":["oic.wk.col"]}],"n":"Smart Plug","ttl":0}
| | 2021-08-13 02:14:55 | 2021-08-12T17:14:55.409Z DEBUG log/log.go:108 observation of resource device_id:"6ec91ff4-60e9-47db-6257-3f05c6867e10" href:"/oic/p" requested
| | 2021-08-13 02:14:55 | 2021-08-12T17:14:55.414Z DEBUG log/log.go:83
| | 2021-08-13 02:14:55 | -------------------SEND-RESPONSE------------------
| | 2021-08-13 02:14:55 | DeviceId: 6ec91ff4-60e9-47db-6257-3f05c6867e10
| | 2021-08-13 02:14:55 | Token: 013a4230a1a5b18f
| | 2021-08-13 02:14:55 | Path:
| | 2021-08-13 02:14:55 | Code: Changed
| | 2021-08-13 02:14:55 | Query: []
| | 2021-08-13 02:14:55 | ContentFormat: application/vnd.ocf+cbor
| | 2021-08-13 02:14:55 | CBOR:
| | 2021-08-13 02:14:55 | {"di":"6ec91ff4-60e9-47db-6257-3f05c6867e10","links":[{"di":"6ec91ff4-60e9-47db-6257-3f05c6867e10","href":"/oic/p","if":["oic.if.r","oic.if.baseline"],"ins":318534269,"p":{"bm":3,"port":0,"sec":false,"x.org.iotivity.tcp":0,"x.org.iotivity.tls":0},"rt":["oic.wk.p"]},{"di":"6ec91ff4-60e9-47db-6257-3f05c6867e10","href":"/oic/d","if":["oic.if.r","oic.if.baseline"],"ins":136750592,"p":{"bm":3,"port":0,"sec":false,"x.org.iotivity.tcp":0,"x.org.iotivity.tls":0},"rt":["oic.d.smartplug","oic.wk.d"]},{"di":"6ec91ff4-60e9-47db-6257-3f05c6867e10","href":"/plug/1","if":["oic.if.a","oic.if.baseline"],"ins":2713892058,"p":{"bm":3,"port":0,"sec":false,"x.org.iotivity.tcp":0,"x.org.iotivity.tls":0},"rt":["oic.r.switch.binary"]},{"di":"6ec91ff4-60e9-47db-6257-3f05c6867e10","href":"/switches","if":["oic.if.ll","oic.if.create","oic.if.b","oic.if.baseline"],"ins":757679238,"p":{"bm":3,"port":0,"sec":false,"x.org.iotivity.tcp":0,"x.org.iotivity.tls":0},"rt":["oic.wk.col"]}],"lt":0,"ttl":0}
| | 2021-08-13 02:14:55 | 2021-08-12T17:14:55.435Z DEBUG log/log.go:83
| | 2021-08-13 02:14:55 | -------------------RECEIVED-NOTIFICATION------------------
| | 2021-08-13 02:14:55 | DeviceId: 6ec91ff4-60e9-47db-6257-3f05c6867e10
| | 2021-08-13 02:14:55 | Token: b909b4621000df0b
| | 2021-08-13 02:14:55 | Path:
| | 2021-08-13 02:14:55 | Code: Content
| | 2021-08-13 02:14:55 | Query: []
| | 2021-08-13 02:14:55 | Observe: 0
| | 2021-08-13 02:14:55 | ContentFormat: application/vnd.ocf+cbor
| | 2021-08-13 02:14:55 | CBOR:
| | 2021-08-13 02:14:55 | {"if":["oic.if.r","oic.if.baseline"],"mnmn":"ocfcloud.com","pi":"abefb29a-886d-42dc-5881-5170c6884204","rt":["oic.wk.p"]}
| | 2021-08-13 02:14:55 | 2021-08-12T17:14:55.436Z DEBUG log/log.go:108 observation of resource device_id:"6ec91ff4-60e9-47db-6257-3f05c6867e10" href:"/oic/d" requested
| | 2021-08-13 02:14:55 | 2021-08-12T17:14:55.466Z DEBUG log/log.go:83
| | 2021-08-13 02:14:55 | -------------------RECEIVED-NOTIFICATION------------------
| | 2021-08-13 02:14:55 | DeviceId: 6ec91ff4-60e9-47db-6257-3f05c6867e10
| | 2021-08-13 02:14:55 | Token: aa7c23e860eee873
| | 2021-08-13 02:14:55 | Path:
| | 2021-08-13 02:14:55 | Code: Content
| | 2021-08-13 02:14:55 | Query: []
| | 2021-08-13 02:14:55 | Observe: 0
| | 2021-08-13 02:14:55 | ContentFormat: application/vnd.ocf+cbor
| | 2021-08-13 02:14:55 | CBOR:
| | 2021-08-13 02:14:55 | {"di":"6ec91ff4-60e9-47db-6257-3f05c6867e10","dmn":[{"language":"en","value":"ocfcloud.com"}],"dmv":"ocf.res.1.3.0,ocf.sh.1.3.0","icv":"ocf.2.0.5","if":["oic.if.r","oic.if.baseline"],"n":"Smart Plug","piid":"c9b9e646-3ffd-4da5-73ec-eef78d0e36ca","rt":["oic.d.smartplug","oic.wk.d"]}
| | 2021-08-13 02:14:55 | 2021-08-12T17:14:55.466Z DEBUG log/log.go:108 observation of resource device_id:"6ec91ff4-60e9-47db-6257-3f05c6867e10" href:"/plug/1" requested
| | 2021-08-13 02:14:55 | 2021-08-12T17:14:55.497Z DEBUG log/log.go:83
| | 2021-08-13 02:14:55 | -------------------RECEIVED-NOTIFICATION------------------
| | 2021-08-13 02:14:55 | DeviceId: 6ec91ff4-60e9-47db-6257-3f05c6867e10
| | 2021-08-13 02:14:55 | Token: 755444bfc16b86e6
| | 2021-08-13 02:14:55 | Path:
| | 2021-08-13 02:14:55 | Code: Content
| | 2021-08-13 02:14:55 | Query: []
| | 2021-08-13 02:14:55 | Observe: 0
| | 2021-08-13 02:14:55 | ContentFormat: application/vnd.ocf+cbor
| | 2021-08-13 02:14:55 | CBOR:
| | 2021-08-13 02:14:55 | {"if":["oic.if.a","oic.if.baseline"],"n":"Switch","rt":["oic.r.switch.binary"],"value":false}
| | 2021-08-13 02:14:55 | 2021-08-12T17:14:55.501Z DEBUG log/log.go:108 observation of resource device_id:"6ec91ff4-60e9-47db-6257-3f05c6867e10" href:"/switches" requested
| | 2021-08-13 02:14:55 | 2021-08-12T17:14:55.525Z DEBUG log/log.go:83
| | 2021-08-13 02:14:55 | -------------------RECEIVED-NOTIFICATION------------------
| | 2021-08-13 02:14:55 | DeviceId: 6ec91ff4-60e9-47db-6257-3f05c6867e10
| | 2021-08-13 02:14:55 | Token: 1d1515190ba7b5ad
| | 2021-08-13 02:14:55 | Path:
| | 2021-08-13 02:14:55 | Code: Content
| | 2021-08-13 02:14:55 | Query: []
| | 2021-08-13 02:14:55 | Observe: 0
| | 2021-08-13 02:14:55 | ContentFormat: application/vnd.ocf+cbor
| | 2021-08-13 02:14:55 | CBOR:
| | 2021-08-13 02:14:55 | {"if":["oic.if.ll","oic.if.create","oic.if.b","oic.if.baseline"],"links":[],"rt":["oic.wk.col"],"rts":["oic.r.switch.binary"],"rts-m":["oic.r.switch.binary"],"x.org.openconnectivity.bl":94}
| | 2021-08-13 02:14:58 | 2021-08-12T17:14:58.200Z DEBUG log/log.go:83
| | 2021-08-13 02:14:58 | -------------------RECEIVED-COMMAND------------------
| | 2021-08-13 02:14:58 | DeviceId: 6ec91ff4-60e9-47db-6257-3f05c6867e10
| | 2021-08-13 02:14:58 | Token: 7d709897839984d6
| | 2021-08-13 02:14:58 | Path: oic/sec/session
| | 2021-08-13 02:14:58 | Code: POST
| | 2021-08-13 02:14:58 | Query: []
| | 2021-08-13 02:14:58 | ContentFormat: application/vnd.ocf+cbor
| | 2021-08-13 02:14:58 | CBOR:
| | 2021-08-13 02:14:58 | {"accesstoken":"eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCIsImtpZCI6ImhPeHdxSzJCM2k5amZjSFo4dVh6QyJ9.eyJodHRwczovL3d3dy5vY2ZjbG91ZC5jb20vdGVuYW50IjoiKiIsImlzcyI6Imh0dHBzOi8vdHJpc2hpYTEyOTguYXV0aDAuY29tLyIsInN1YiI6ImF1dGgwfDYxMTI0NjdmM2E4M2E4MDA3MGJjNjk5ZCIsImF1ZCI6Imh0dHBzOi8vd3d3Lm9jZmNsb3VkLmNvbSIsImlhdCI6MTYyODc4ODQ3MSwiZXhwIjoxNjI4ODc0ODcxLCJhenAiOiJEZ2V6THlXczFoSFJmNjkxNHRreVVkcDRRRG1rVm1ueiIsInNjb3BlIjoicjpkZXZpY2VpbmZvcm1hdGlvbjoqIHI6cmVzb3VyY2VzOiogdzpyZXNvdXJjZXM6KiB3OnN1YnNjcmlwdGlvbnM6KiBvZmZsaW5lX2FjY2VzcyJ9.vYrpnKLzxx0kurIZd3VI8fu93Tb5LyP85H8iDQtYkhuGwVNi-nmFr_h0GQoucssIvFkjEsKi9_HYVtO2duhlLAWpiFHqfV24NqymynpllUCAETicdtg6_OV1j4G02GRefPL-wN1EGHutHnG2h8UMxfphwA70PgO29eVmz49EXPJMsbj7l8DfhFvBPOEOfyXgYq-_JDVO52JTFeq1lK7CC53OM76TA2wIkdt5wSDKY5NT3vbiO47Sda0vz86d-LcGCkbUg3_iyPV5NeupFLGKASk1QwfiT9bG4rCHpPJs3a9Pomrn3xw88AtTeXmSLc6dCr2gutP4KP85qM3alPGMzQ","di":"6ec91ff4-60e9-47db-6257-3f05c6867e10","login":true,"uid":"auth0\|6112467f3a83a80070bc699d"}
| | 2021-08-13 02:14:58 | 2021-08-12T17:14:58.201Z DEBUG log/log.go:108 Authorization context replaced for client 10.1.2.223:54580, device 6ec91ff4-60e9-47db-6257-3f05c6867e10, user auth0\|6112467f3a83a80070bc699d
| | 2021-08-13 02:14:58 | 2021-08-12T17:14:58.220Z DEBUG log/log.go:83
| | 2021-08-13 02:14:58 | -------------------SEND-RESPONSE------------------
| | 2021-08-13 02:14:58 | DeviceId: 6ec91ff4-60e9-47db-6257-3f05c6867e10
| | 2021-08-13 02:14:58 | Token: 7d709897839984d6
| | 2021-08-13 02:14:58 | Path:
| | 2021-08-13 02:14:58 | Code: Changed
| | 2021-08-13 02:14:58 | Query: []
| | 2021-08-13 02:14:58 | ContentFormat: application/vnd.ocf+cbor
| | 2021-08-13 02:14:58 | CBOR:
| | 2021-08-13 02:14:58 | {"expiresin":86372}
| | 2021-08-13 02:14:58 | 2021-08-12T17:14:58.240Z DEBUG log/log.go:108 observation of resource device_id:"6ec91ff4-60e9-47db-6257-3f05c6867e10" href:"/oic/d" requested
| | 2021-08-13 02:14:58 | 2021-08-12T17:14:58.241Z DEBUG log/log.go:108 observation of resource device_id:"6ec91ff4-60e9-47db-6257-3f05c6867e10" href:"/plug/1" requested
| | 2021-08-13 02:14:58 | 2021-08-12T17:14:58.241Z DEBUG log/log.go:108 observation of resource device_id:"6ec91ff4-60e9-47db-6257-3f05c6867e10" href:"/switches" requested
| | 2021-08-13 02:14:58 | 2021-08-12T17:14:58.242Z DEBUG log/log.go:108 observation of resource device_id:"6ec91ff4-60e9-47db-6257-3f05c6867e10" href:"/oic/p" requested
| | 2021-08-13 02:14:58 | 2021-08-12T17:14:58.244Z DEBUG log/log.go:83
| | 2021-08-13 02:14:58 | -------------------RECEIVED-COMMAND------------------
| | 2021-08-13 02:14:58 | DeviceId: 6ec91ff4-60e9-47db-6257-3f05c6867e10
| | 2021-08-13 02:14:58 | Token: 1cd105e25508f80e
| | 2021-08-13 02:14:58 | Path: oic/rd
| | 2021-08-13 02:14:58 | Code: POST
| | 2021-08-13 02:14:58 | Query: [rt=oic.wk.rdpub]
| | 2021-08-13 02:14:58 | ContentFormat: application/vnd.ocf+cbor
| | 2021-08-13 02:14:58 | CBOR:
| | 2021-08-13 02:14:58 | {"di":"6ec91ff4-60e9-47db-6257-3f05c6867e10","links":[{"href":"/oic/p","if":["oic.if.r","oic.if.baseline"],"ins":318534269,"p":{"bm":3},"rel":"hosts","rt":["oic.wk.p"]},{"href":"/oic/d","if":["oic.if.r","oic.if.baseline"],"ins":136750592,"p":{"bm":3},"rel":"hosts","rt":["oic.d.smartplug","oic.wk.d"]},{"href":"/plug/1","if":["oic.if.a","oic.if.baseline"],"ins":2713892058,"p":{"bm":3},"rel":"hosts","rt":["oic.r.switch.binary"]},{"href":"/switches","if":["oic.if.ll","oic.if.create","oic.if.b","oic.if.baseline"],"ins":757679238,"p":{"bm":3},"rel":"hosts","rt":["oic.wk.col"]}],"n":"Smart Plug","ttl":0}
| | 2021-08-13 02:14:58 | 2021-08-12T17:14:58.281Z DEBUG log/log.go:83
| | 2021-08-13 02:14:58 | -------------------SEND-RESPONSE------------------
| | 2021-08-13 02:14:58 | DeviceId: 6ec91ff4-60e9-47db-6257-3f05c6867e10
| | 2021-08-13 02:14:58 | Token: 1cd105e25508f80e
| | 2021-08-13 02:14:58 | Path:
| | 2021-08-13 02:14:58 | Code: Changed
| | 2021-08-13 02:14:58 | Query: []
| | 2021-08-13 02:14:58 | ContentFormat: application/vnd.ocf+cbor
| | 2021-08-13 02:14:58 | CBOR:
| | 2021-08-13 02:14:58 | {"di":"6ec91ff4-60e9-47db-6257-3f05c6867e10","links":[{"di":"6ec91ff4-60e9-47db-6257-3f05c6867e10","href":"/oic/p","if":["oic.if.r","oic.if.baseline"],"ins":318534269,"p":{"bm":3,"port":0,"sec":false,"x.org.iotivity.tcp":0,"x.org.iotivity.tls":0},"rt":["oic.wk.p"]},{"di":"6ec91ff4-60e9-47db-6257-3f05c6867e10","href":"/oic/d","if":["oic.if.r","oic.if.baseline"],"ins":136750592,"p":{"bm":3,"port":0,"sec":false,"x.org.iotivity.tcp":0,"x.org.iotivity.tls":0},"rt":["oic.d.smartplug","oic.wk.d"]},{"di":"6ec91ff4-60e9-47db-6257-3f05c6867e10","href":"/plug/1","if":["oic.if.a","oic.if.baseline"],"ins":2713892058,"p":{"bm":3,"port":0,"sec":false,"x.org.iotivity.tcp":0,"x.org.iotivity.tls":0},"rt":["oic.r.switch.binary"]},{"di":"6ec91ff4-60e9-47db-6257-3f05c6867e10","href":"/switches","if":["oic.if.ll","oic.if.create","oic.if.b","oic.if.baseline"],"ins":757679238,"p":{"bm":3,"port":0,"sec":false,"x.org.iotivity.tcp":0,"x.org.iotivity.tls":0},"rt":["oic.wk.col"]}],"lt":0,"ttl":0}