java.net.UnknownHostException: https-proxy.service - bouncycastle

I am trying to add BCFIPS in my service, my testcase started failing after adding configuration for bcfips.
Provider: KeyPairGenerator.EC algorithm from: BCFIPS
Provider: KeyPairGenerator.EC algorithm from: BCFIPS
Mon Mar 28 10:29:37.494 IST 2022 [http-nio-auto-1-exec-2] [c.s.a.s.f.f.s.o.TokenStoringUserInfoTokenService: ERROR] - Exception on authentication: java.net.UnknownHostException: https-proxy.service
Provider: KeyStore.FIPS type from: BCFIPS
org.opentest4j.AssertionFailedError:
expected: 200 OK
but was: 401 UNAUTHORIZED
Expected :200 OK
Actual :401 UNAUTHORIZED

Related

Use international characters in azure storage metadata?

When I run this request using this azure library:
blobURL.PutBlob(ctx, strings.NewReader("Some text"), azblob.BlobHTTPHeaders{}, azblob.Metadata{"Foo": "/愛知県/bar"}, azblob.BlobAccessConditions{})
I get this error:
===== RESPONSE ERROR (ServiceCode=AuthenticationFailed) =====
Description=Server failed to authenticate the request. Make sure the value of Authorization header is formed correctly including the signature.
RequestId:daf8a672-001e-000e-2f4b-a033f3000000
Time:2018-02-07T19:38:09.6740273Z, Details:
AuthenticationErrorDetail: The MAC signature found in the HTTP request 'REDACTED' is not the same as any computed signature. Server used following string to sign: 'PUT
9
x-ms-blob-cache-control:
x-ms-blob-content-disposition:
x-ms-blob-content-encoding:
x-ms-blob-content-language:
x-ms-blob-content-type:
x-ms-blob-type:BlockBlob
x-ms-client-request-id:f18fd538-3780-4f62-5236-777ac244affa
x-ms-date:Wed, 07 Feb 2018 19:38:09 GMT
x-ms-meta-foo:/愛知県/bar
x-ms-version:2016-05-31
/MYACCOUNT/MYCONTAINER/ReadMe.txt
timeout:61.
PUT https://MYACCOUNT.blob.core.cloudapi.de/MYCONTAINER/ReadMe.txt?timeout=61
Authorization: REDACTED
Content-Length: [9]
User-Agent: [Azure-Storage/0.1 (go1.9.3; darwin)]
X-Ms-Blob-Cache-Control: []
X-Ms-Blob-Content-Disposition: []
X-Ms-Blob-Content-Encoding: []
X-Ms-Blob-Content-Language: []
X-Ms-Blob-Content-Type: []
X-Ms-Blob-Type: [BlockBlob]
X-Ms-Client-Request-Id: [f18fd538-3780-4f62-5236-777ac244affa]
X-Ms-Date: [Wed, 07 Feb 2018 19:38:09 GMT]
X-Ms-Meta-Foo: [/愛知県/bar]
X-Ms-Version: [2016-05-31]
--------------------------------------------------------------------------------
RESPONSE Status: 403 Server failed to authenticate the request. Make sure the value of Authorization header is formed correctly including the signature.
Content-Length: [936]
Content-Type: [application/xml]
Date: [Wed, 07 Feb 2018 19:38:09 GMT]
Server: [Microsoft-HTTPAPI/2.0]
X-Ms-Request-Id: [daf8a672-001e-000e-2f4b-a033f3000000]
exit status 1
Is this because "/愛知県/bar" != "/愛知県/bar"?
Do you see any way to set non-ascii character like "/愛知県/bar" as a metadata value?
Since you mentioned Go in the tag, I assume you are looking for using a transliterator, there is this one in github which you should try
: https://github.com/rainycape/unidecode

Strange Config file error

I am working on an application which requires AWS (Amazon Web Services) push notification services.
I am running this on a node server, when I run the curl http request I get this error:
Registering user with deviceId: nodeserver
{ [Error: Missing credentials in config]
message: 'Missing credentials in config',
code: 'SigningError',
time: Tue Nov 17 2015 13:52:20 GMT+0000 (GMT),
originalError:
{ message: 'Could not load credentials from any providers',
code: 'CredentialsError',
time: Tue Nov 17 2015 13:52:20 GMT+0000 (GMT),
originalError:
{ message: 'Connection timed out after 1000ms',
code: 'TimeoutError',
time: Tue Nov 17 2015 13:52:20 GMT+0000 (GMT) } } }
Does anybody know what this error is or if anybody has had this type of error before and knows how to go about fixing it?

How to setup custom DNS with Azure Websites Preview?

I created a new Azure Website, using Umbraco as the CMS. I got a page up and going, and I already have a .co.nz domain with www.domains4less.com. There's a whole lot of stuff on the internet about pointing URLs to Azure, but that seems to be more of a redirection service than anything (i.e. my URLs still use azurewebsites.net once I land on my site).
Has anybody had any luck getting it to go?
Here's the error I get when I try adding the DNS entry to Azure (I'm in reserved mode, reemdairy is the name of the website):
There was an error processing your request. Please try again in a few
moments.
Browser: 5.0 (Windows NT 6.1; WOW64) AppleWebKit/536.5 (KHTML, like
Gecko) Chrome/19.0.1084.56 Safari/536.5 User language: undefined
Portal Version: 6.0.6002.18488 (rd_auxportal_stable.120609-0259)
Subscriptions: 3aabe358-d178-4790-a97b-ffba902b2851 User email
address: touchmaniacs#live.com
Last 10 Requests
message: Failure: Ajax call to: Websites/UpdateConfig. failed with
status: error (500) in 2.57 seconds. x-ms-client-request-id was:
38834edf-c9f3-46bb-a1f7-b2839c692bcf-2012-06-12 22:25:14Z dateTime:
Wed Jun 13 2012 10:25:17 GMT+1200 (New Zealand Standard Time)
durationSeconds: 2.57 url: Websites/UpdateConfig status: 500
textStatus: error clientMsRequestId:
38834edf-c9f3-46bb-a1f7-b2839c692bcf-2012-06-12 22:25:14Z sessionId:
09c72263-6ce7-422b-84d7-4c21acded759 referrer:
https://manage.windowsazure.com/#Workspaces/WebsiteExtension/Website/reemdairy/configure
host: manage.windowsazure.com response: {"message":"Try again. Contact
support if the problem persists.","ErrorMessage":"Try again. Contact
support if the problem
persists.","httpStatusCode":"InternalServerError","operationTrackingId":"","stackTrace":null}
message: Complete: Ajax call to: Websites/GetConfig. completed with
status: success (200) in 1.021 seconds. x-ms-client-request-id was:
a0cdcced-13d0-44e2-866d-e0b061b9461b-2012-06-12 22:24:43Z dateTime:
Wed Jun 13 2012 10:24:44 GMT+1200 (New Zealand Standard Time)
durationSeconds: 1.021 url: Websites/GetConfig status: 200 textStatus:
success clientMsRequestId:
a0cdcced-13d0-44e2-866d-e0b061b9461b-2012-06-12 22:24:43Z sessionId:
09c72263-6ce7-422b-84d7-4c21acded759 referrer:
https://manage.windowsazure.com/#Workspaces/WebsiteExtension/Website/reemdairy/configure
host: manage.windowsazure.com
message: Complete: Ajax call to:
https://manage.windowsazure.com/Service/OperationTracking?subscriptionId=3aabe358-d178-4790-a97b-ffba902b2851.
completed with status: success (200) in 1.887 seconds.
x-ms-client-request-id was:
a7689fe9-b9f9-4d6c-8926-734ec9a0b515-2012-06-12 22:24:40Z dateTime:
Wed Jun 13 2012 10:24:42 GMT+1200 (New Zealand Standard Time)
durationSeconds: 1.887 url:
https://manage.windowsazure.com/Service/OperationTracking?subscriptionId=3aabe358-d178-4790-a97b-ffba902b2851
status: 200 textStatus: success clientMsRequestId:
a7689fe9-b9f9-4d6c-8926-734ec9a0b515-2012-06-12 22:24:40Z sessionId:
09c72263-6ce7-422b-84d7-4c21acded759 referrer:
https://manage.windowsazure.com/#Workspaces/WebsiteExtension/Website/reemdairy/configure
host: manage.windowsazure.com
message: Complete: Ajax call to: /Service/GetUserSettings. completed
with status: success (200) in 0.941 seconds. x-ms-client-request-id
was: 805e554d-1e2e-4214-afd5-be87c0f255d1-2012-06-12 22:24:40Z
dateTime: Wed Jun 13 2012 10:24:40 GMT+1200 (New Zealand Standard
Time) durationSeconds: 0.941 url: /Service/GetUserSettings status: 200
textStatus: success clientMsRequestId:
805e554d-1e2e-4214-afd5-be87c0f255d1-2012-06-12 22:24:40Z sessionId:
09c72263-6ce7-422b-84d7-4c21acded759 referrer:
https://manage.windowsazure.com/#Workspaces/WebsiteExtension/Website/reemdairy/configure
host: manage.windowsazure.com
message: Complete: Ajax call to:
Extensions/ApplicationsExtension/SqlAzure/ClusterSuffix. completed
with status: success (200) in 0.483 seconds. x-ms-client-request-id
was: 85157ceb-c538-40ca-8c1e-5cc07c57240f-2012-06-12 22:24:39Z
dateTime: Wed Jun 13 2012 10:24:40 GMT+1200 (New Zealand Standard
Time) durationSeconds: 0.483 url:
Extensions/ApplicationsExtension/SqlAzure/ClusterSuffix status: 200
textStatus: success clientMsRequestId:
85157ceb-c538-40ca-8c1e-5cc07c57240f-2012-06-12 22:24:39Z sessionId:
09c72263-6ce7-422b-84d7-4c21acded759 referrer:
https://manage.windowsazure.com/#Workspaces/WebsiteExtension/Website/reemdairy/configure
host: manage.windowsazure.com
message: Complete: Ajax call to:
Extensions/ApplicationsExtension/SqlAzure/GetClientIp. completed with
status: success (200) in 0.309 seconds. x-ms-client-request-id was:
2eb194b6-66ca-49e2-9016-e0f89164314c-2012-06-12 22:24:39Z dateTime:
Wed Jun 13 2012 10:24:40 GMT+1200 (New Zealand Standard Time)
durationSeconds: 0.309 url:
Extensions/ApplicationsExtension/SqlAzure/GetClientIp status: 200
textStatus: success clientMsRequestId:
2eb194b6-66ca-49e2-9016-e0f89164314c-2012-06-12 22:24:39Z sessionId:
09c72263-6ce7-422b-84d7-4c21acded759 referrer:
https://manage.windowsazure.com/#Workspaces/WebsiteExtension/Website/reemdairy/configure
host: manage.windowsazure.com
message: Complete: Ajax call to:
Extensions/ApplicationsExtension/SqlAzure/DefaultServerLocation.
completed with status: success (200) in 0.309 seconds.
x-ms-client-request-id was:
1bc165ef-2081-48f2-baed-16c6edf8ea67-2012-06-12 22:24:39Z dateTime:
Wed Jun 13 2012 10:24:40 GMT+1200 (New Zealand Standard Time)
durationSeconds: 0.309 url:
Extensions/ApplicationsExtension/SqlAzure/DefaultServerLocation
status: 200 textStatus: success clientMsRequestId:
1bc165ef-2081-48f2-baed-16c6edf8ea67-2012-06-12 22:24:39Z sessionId:
09c72263-6ce7-422b-84d7-4c21acded759 referrer:
https://manage.windowsazure.com/#Workspaces/WebsiteExtension/Website/reemdairy/configure
host: manage.windowsazure.com
message: Complete: Ajax call to:
Extensions/ApplicationsExtension/SqlAzure/ServerLocations. completed
with status: success (200) in 0.309 seconds. x-ms-client-request-id
was: e1fba7df-6a12-47f8-9434-bf17ca7d93f4-2012-06-12 22:24:39Z
dateTime: Wed Jun 13 2012 10:24:40 GMT+1200 (New Zealand Standard
Time) durationSeconds: 0.309 url:
Extensions/ApplicationsExtension/SqlAzure/ServerLocations status: 200
textStatus: success clientMsRequestId:
e1fba7df-6a12-47f8-9434-bf17ca7d93f4-2012-06-12 22:24:39Z sessionId:
09c72263-6ce7-422b-84d7-4c21acded759 referrer:
https://manage.windowsazure.com/#Workspaces/WebsiteExtension/Website/reemdairy/configure
host: manage.windowsazure.com
Its good that you have Windows Azure Website (Reserve) because only Reserve websites can have CNAME or A record point to your_site.azurewebsites.net.
May I ask what are you setting, CNAME or A Record?
Here is the step by step direction on setting either CNAME (which is suggested for websites and webroles) so please follow and suggest at what step you have an issue:
Configuring a Custom Domain Name in Windows Azure
I've successfully done this with the exact same setup (Umbraco, running on Azure with a domains4less.co.nz domain). DNS setup with Domains4less can be obtuse - but here's how to setup a CNAME to your app:
From 'Manage Domains', hit 'Setup' on the domain you want. Next page, 'Advanced Control Panel' and login. Expand 'Services', open 'Domain Templates' and click 'Add a domain template'
Give your template a name (e.g 'yourdomain.co.nz'), and scroll down to the CNAME Records section. Click 'Add a CNAME record', Prefix field: www, Destination Address: YOURAPPNAME.azurewebsites.net.. Save.
Open 'Domains' in the left-side menu and click '[edit]' on the domain you want to setup, open the 'Advanced Mode' tab and choose your template from the Template drop-down list. Save, done.
Phew.

401 unauthorized on final REGISTER Handshake on custom lync-client

I have implemented ntlmv2 for lync-server login in an custom made lync client.The message that I send to server is .....
(3rd register message)
REGISTER sip:example.com SIP/2.0
Via: SIP/2.0/TLS 19x.1xx.0.1xx:3246
From: <sip:lynctest8#example.com>;tag=2257063211;epid=22570632
To: <sip:lynctest8#example.com>
Call-ID: A2B000F95CB8XZRikcdYitb4QBvEr4P2
CSeq: 3 REGISTER
Contact: <sip:19x.1xx.0.1xx:3246;transport=tls;ms-opaque=28c9d310c1>;methods="INVITE, MESSAGE, INFO, OPTIONS, BYE, CANCEL, NOTIFY, ACK, REFER, BENOTIFY";proxy=replace;+sip.instance="<urn:uuid:6b6590c5-2a3f-5dee-ad87-5ab6694cf66d>"
Max-Forwards: 70
User-Agent: UCCAPI/4.0.7577.0 OC/4.0.7577.0 (Microsoft Lync 2010)
Supported: gruu-10, adhoclist, msrtc-event-categories
Supported: ms-forking
Supported: ms-cluster-failover
Supported: ms-userservices-state-notification
Ms-keep-alive: UAC;hop-hop=yes
Event: registration
Ms-subnet: 19x.1xx.0.0
Proxy-Authorization: NTLM qop="auth", realm="SIP Communications Service", opaque="8CEED616", targetname="lyncfe.example.com", version=4, gssapi-data="TlRMTVNTUAADAAAAGAAYAKgAAADGAMYAwAAAABAAEABYAAAALAAsAGgAAAAUABQAlAAAABAAEACGAQAAVYKQYgYBsR0AAAAPAAAAAAAAAAAAAAAAAAAAAG4AZQB5AGUAYgBhAGwAbABsAHkAbgBjAHQAZQBzAHQAOABAAG4AZQB5AGUAYgBhAGwAbAAuAGMAbwBtAEUAWQBFAEIAQQBMAEwALQBQAEMA9jYBMVaneo2SEFBrg1/YnLPWl4gGzCyjeTg+SJIb99jnRvh/xOM1KQEBAAAAAAAAAD9j2kfbzAGz1peIBswsowAAAAACABAATgBFAFkARQBCAEEATABMAAEADABMAFkATgBDAEYARQAEABgAbgBlAHkAZQBiAGEAbABsAC4AYwBvAG0AAwAmAGwAeQBuAGMAZgBlAC4AbgBlAHkAZQBiAGEAbABsAC4AYwBvAG0ABQAYAG4AZQB5AGUAYgBhAGwAbAAuAGMAbwBtAAcACABjQk/rRdvMAQAAAAAAAAAAGL4kYo+YoVBEmij7AkIylQ==" , crand="becdaa89", cnum ="1", response="0100000024A95BA08AA3947964000000"
Content-Length: 0
The response that I get from server is in log is......
TL_INFO(TF_COMPONENT) [0]05FC.02D0::01/25/2012-08:06:57.900.00000042 (SIPStack,CSIPMessage::CacheConnectionFlags:SIPMessage.cpp(1664))[0]( 00000000039B4DC0 ) From server [lyncfe.example.com] connection, flags [PeerInternal TrafficInternal 0xa0100c], CID [0x12300]
TL_INFO(TF_PROTOCOL) [0]05FC.02D0::01/25/2012-08:06:57.900.00000043 (SIPStack,SIPAdminLog::TraceProtocolRecord:SIPAdminLog.cpp(125))$$begin_record
Trace-Correlation-Id: 4074196035
Instance-Id: 000018F0
Direction: incoming;source="internal edge";destination="external edge"
Peer: lyncfe.example.com:5061
Message-Type: response
Start-Line: SIP/2.0 401 Unauthorized
From: <sip:lynctest8#example.com>;tag=1672455111;epid=16724551
To: <sip:lynctest8#example.com>;tag=6E92C85AEBAC66461CD3D9E7FF35D674
CSeq: 3 REGISTER
Call-ID: CDEA0494B083GDXKgQYZ3IuhqvqePNLL
Date: Wed, 25 Jan 2012 08:06:57 GMT
WWW-Authenticate: NTLM realm="SIP Communications Service", targetname="lyncfe.example.com", version=4
WWW-Authenticate: TLS-DSK realm="SIP Communications Service", targetname="lyncfe.example.com", version=4, sts-uri="https://lyncfe.example.com:443/CertProv/CertProvisioningService.svc"
Via: SIP/2.0/TLS 19x.1xx.0.2xx:60027;branch=z9hG4bK72A5FBC9.AAC299504F0761A1;branched=FALSE;ms-received-port=60027;ms-received-cid=16B9100
Via: SIP/2.0/TLS 19x.1xx.0.1xx:3082;received=2xx.xx.1xx.1xx;ms-received-port=3082;ms-received-cid=12700
ms-diagnostics: 1000;reason="Final handshake failed";HRESULT="0xC3E93EC3(SIP_E_AUTH_UNAUTHORIZED)";source="lyncfe.example.com"
Server: RTC/4.0
Content-Length: 0
Message-Body: –
$$end_record
What is the problem here? Can you give any hints/solutions to solve it?
It most likely due to SSL handshake while end point "https://lyncfe.example.com:443/CertProv/CertProvisioningService.svc". Please check your client certs and also enable SSL debug to see what's happening during handshake.
Thanks, Everyone. My problem has been solved. It was GSS-API-data and auth-token generation problem.

Error during couchdb filtered replication with params

I'm trying to run a filtered replication on two different machines, I realized that this only happens when doing a pull replication, if I do a push replication it works fine.
curl -X POST http://localhost:5984/_replicate -d '{\"source\":\"http://MARTIN-NEWPC:5984/pdlib\",\"target\":\"pdlib\",\"filter\":\"replication/SINGLE_COLLECTION\",\"query_params\":{\"key\":\"bb579347-9bfb-4dda-84eb-622b43108872\"}}' -H "Content-Type: application/json"
The cryptic response I get from that request is:
{"error":"json_encode", "reason":"{bad_term, <0.20050.0>}"}
And the debug output in the target couchdb log file is:
[Mon, 17 Oct 2011 01:20:48 GMT] [debug] [<0.476.0>] 'GET' /pdlib/_changes?key=bb579347-9bfb-4dda-84eb-622b43108872&filter=replication/SINGLE_COLLECTION&style=all_docs&heartbeat=10000&since=0&feed=normal {1,
1}
Headers: [{'Accept',"application/json"},
{'Content-Length',"0"},
{'Host',"MARTIN-NEWPC:5984"},
{'User-Agent',"CouchDB/1.0.2"}]
[Mon, 17 Oct 2011 01:20:48 GMT] [debug] [<0.476.0>] OAuth Params: [{"key","bb579347-9bfb-4dda-84eb-622b43108872"},
{"filter","replication/SINGLE_COLLECTION"},
{"style","all_docs"},
{"heartbeat","10000"},
{"since","0"},
{"feed","normal"}]
[Mon, 17 Oct 2011 01:20:48 GMT] [info] [<0.476.0>] 192.168.2.3 - - 'GET' /pdlib/_changes?key=bb579347-9bfb-4dda-84eb-622b43108872&filter=replication/SINGLE_COLLECTION&style=all_docs&heartbeat=10000&since=0&feed=normal 200
[Mon, 17 Oct 2011 01:20:48 GMT] [error] [<0.476.0>] attempted upload of invalid JSON (set log_level to debug to log it)
[Mon, 17 Oct 2011 01:20:48 GMT] [debug] [<0.476.0>] Invalid JSON: <<"bb579347-9bfb-4dda-84eb-622b43108872">>
[Mon, 17 Oct 2011 01:20:48 GMT] [info] [<0.476.0>] 192.168.2.3 - - 'GET' /pdlib/_changes?key=bb579347-9bfb-4dda-84eb-622b43108872&filter=replication/SINGLE_COLLECTION&style=all_docs&heartbeat=10000&since=0&feed=normal 400
[Mon, 17 Oct 2011 01:20:48 GMT] [debug] [<0.476.0>] httpd 400 error response:
{"error":"bad_request","reason":"invalid UTF-8 JSON"}
In case you need to know, this is the filter function:
function (doc, req) {
if (doc.type == 'collection' || doc.type == 'document') {
for (var i in doc.path) {
if (doc.path[i] == req.query.key) {
return true;
}
}
}
return false;
}
Any ideas about the possible cause?
It's common to get a 400 "invalid UTF-8 JSON" error when CouchDB tries to interpret one of your query values as JSON when it's a raw (unquoted) string instead. In this case the replication config results in this HTTP request:
GET /pdlib/_changes?key=bb579347-9bfb-4dda-84eb-622b43108872&filter=replication/SINGLE_COLLECTION&style=all_docs&heartbeat=10000&since=0&feed=normal 400
The _changes feed itself doesn't use a key parameter, but normal CouchDB _view queries do — and there expect it to be a JSON value! — so you might try renaming that query_param to something different.
(Somewhat unfortunately, user-defined filter (and list, etc.) functions share the query parameter namespace with CouchDB itself...you may want to prefix your custom parameters with something that's unlikely to conflict with current or future builtin options, e.g. myapp_key.)
Looks to me like there is something wrong with the way you have your JSON escaped. This works for me:
curl -X POST http://localhost:5984/_replicate -d '{"source":"source_db","target":"target_db","filter":"ddoc/filter-name","query_params":{"key":"some_key"}}' -H "Content-Type: application/json"

Resources