When I try your above method to push the file to /service/upload path but I get 401 error, I don't know where I went wrong please help me.
I send you the command I execute and the content of the file login_cookies
Code: Select all
[admin2@mail ~]$ curl -k -X POST -b login_cookies -H "Content-Type: text/html" -H "Content-Disposition: attachment: filename=\'table3.html\'" -d @table3.html https://mail.baovietbank.local/service/upload
<html><head><script language='javascript'>
function doit() { window.parent._uploadManager.loaded(401,'null'); }
</script></head><body onload='doit()'></body></html>
Code: Select all
[admin2@mail ~]$ cat login_cookies
{
"Header":{
"context":{
"change":{
"token":639
},
"_jsns":"urn:zimbra"
}
},
"Body":{
"AuthResponse":{
"authToken":[
{
"_content":"[redacted]"
}
],
"lifetime":172799998,
"skin":[
{
"_content":"harmony"
}
],
"_jsns":"urn:zimbraAccount"
}
},
"_jsns":"urn:zimbraSoap"
}