I'm doing some REST calls on our HPE Aruba switches but I run into a weird error. I've setup calls to our 3810M switches (KB_16_10_0011) and they work fine. On our 2920 switches (WB_16_10_0010) I can only call the REST api's from Postman but all calls from powershell fail. On the 3810M's I can both call from Postman and powershell, both http and ssl.
Here is what happens in Postman on de 2920 (I can't upload pictures):
POST: http://192.168.141.250/rest/v7/login-sessions
BODY: {"userName":"Admin", "password":"###########"}
RESULT:
{
"payloadSize": 16384,
"uri": "/login-sessions",
"cookie": "sessionId=WnWeHeoigJ4FMsDmf6CvV4ZJLcWbjmjhLqfTwXyzLTw9QMLmB5a3eOjlaSGEZEM"
}
This all works fine, I get a session ID.
In Postman I can click on code and I can generate a powershell script:
$headers = New-Object "System.Collections.Generic.Dictionary[[String],[String]]"
$headers.Add("Content-Type", "application/json")
$body = "{`"userName`":`"Admin`", `"password`":`"###########`"}"
$response | ConvertTo-Json
If I run this script to the 2920 I get an error:
However this same piece of code works fine to our 3810M switches. I've tested with adding cookies to the request but this doesn't make a difference.
I've wireshark'd the requests from Postman and Powershell and they are identical except for 1 thing; the request from Postman is always send in 1 TCP segment and the request from powershell is always send in 2 TCP segments. However you might think that switches can handle TCP segments
Anybody got a clue? For now it seems most likely to me there is some bug in de 2920 switches...