> > But depending on attribute order is bad, so I would use the following
> > instead:
> >
> > TICKET=${DATA//\"/}
> > TICKET=${TICKET##*ticket:}
> > TICKET=${TICKET%%,*}
> >
> > CSRF=${DATA//\"/}
> > CSRF=${CSRF##*CSRFPreventionToken:}
> > CSRF=${CSRF%%,*}
> >
> > I guess that would also work?
> 
> Of course but the script works even if the attribute order SHOULD be good

Sorry, I do not understand that. You do:

TICKET=${TICKET%%,username*}

So this will only work if ticket is followed by username. But there is no 
guaranteed for that.

> you have the same problem with sed

I cannot see that problem with sed? 
_______________________________________________
pve-user mailing list
[email protected]
http://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-user

Reply via email to