Documentation
¶
Overview ¶
Package pydhttp contains all http related work
Copyright 2007-2016 Abstrium <contact (at) pydio.com> * This file is part of Pydio. * * Pydio is free software: you can redistribute it and/or modify * it under the terms of the GNU Affero General Public License as published by * the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * * Pydio is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU Affero General Public License for more details. * * You should have received a copy of the GNU Affero General Public License * along with Pydio. If not, see <http://www.gnu.org/licenses/>. * * The latest code can be found at <https://pydio.com/>.
Package pydhttp contains all http related work
Copyright 2007-2016 Abstrium <contact (at) pydio.com> * This file is part of Pydio. * * Pydio is free software: you can redistribute it and/or modify * it under the terms of the GNU Affero General Public License as published by * the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * * Pydio is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU Affero General Public License for more details. * * You should have received a copy of the GNU Affero General Public License * along with Pydio. If not, see <http://www.gnu.org/licenses/>. * * The latest code can be found at <https://pydio.com/>.
Package pydhttp contains all http related work
- Copyright 2007-2016 Abstrium <contact (at) pydio.com>
- This file is part of Pydio. *
- Pydio is free software: you can redistribute it and/or modify
- it under the terms of the GNU Affero General Public License as published by
- the Free Software Foundation, either version 3 of the License, or
- (at your option) any later version. *
- Pydio is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU Affero General Public License for more details. *
- You should have received a copy of the GNU Affero General Public License
- along with Pydio. If not, see <http://www.gnu.org/licenses/>. *
- The latest code can be found at <https://pydio.com/>.
Package pydhttp contains all http related work
- Copyright 2007-2016 Abstrium <contact (at) pydio.com>
- This file is part of Pydio. *
- Pydio is free software: you can redistribute it and/or modify
- it under the terms of the GNU Affero General Public License as published by
- the Free Software Foundation, either version 3 of the License, or
- (at your option) any later version. *
- Pydio is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU Affero General Public License for more details. *
- You should have received a copy of the GNU Affero General Public License
- along with Pydio. If not, see <http://www.gnu.org/licenses/>. *
- The latest code can be found at <https://pydio.com/>.
Package pydhttp contains all http related work
- Copyright 2007-2016 Abstrium <contact (at) pydio.com>
- This file is part of Pydio. *
- Pydio is free software: you can redistribute it and/or modify
- it under the terms of the GNU Affero General Public License as published by
- the Free Software Foundation, either version 3 of the License, or
- (at your option) any later version. *
- Pydio is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU Affero General Public License for more details. *
- You should have received a copy of the GNU Affero General Public License
- along with Pydio. If not, see <http://www.gnu.org/licenses/>. *
- The latest code can be found at <https://pydio.com/>.
Package pydhttp contains all http related work
- Copyright 2007-2016 Abstrium <contact (at) pydio.com>
- This file is part of Pydio. *
- Pydio is free software: you can redistribute it and/or modify
- it under the terms of the GNU Affero General Public License as published by
- the Free Software Foundation, either version 3 of the License, or
- (at your option) any later version. *
- Pydio is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU Affero General Public License for more details. *
- You should have received a copy of the GNU Affero General Public License
- along with Pydio. If not, see <http://www.gnu.org/licenses/>. *
- The latest code can be found at <https://pydio.com/>.
Index ¶
- Variables
- func FromContext(ctx context.Context, key interface{}, value interface{}) (err error)
- func NewContext(ctx context.Context, key interface{}, value interface{}) context.Context
- type API
- type Auth
- type Client
- type ContextValue
- type Cookie
- type CookieMatcher
- type Decoder
- type Encoder
- type Status
- type Token
- func NewToken(token string, password string) *Token
- func NewTokenFromJWT(str string, signatureSecret string) (token *Token, err error)
- func NewTokenFromURLWithBasicAuth(url *url.URL, username string, password string) (token *Token, err error)
- func NewTokenFromURLWithCookie(url *url.URL, cookie *http.Cookie) (token *Token, err error)
Constants ¶
This section is empty.
Variables ¶
var ( // ErrRedirectViaPydioClient is the error used on CheckRedirect ErrRedirectViaPydioClient = errors.New("Redirection is handled by the Pydio HTTP Client") )
Functions ¶
func FromContext ¶
FromContext value of the given key
Types ¶
type API ¶
type API struct {
// contains filtered or unexported fields
}
API data
func (*API) GetBaseURL ¶
GetBaseURL returns the api base url
func (*API) GetQueryArgs ¶
GetQueryArgs based on the uri given for the API auth
type ContextValue ¶
type ContextValue struct {
// contains filtered or unexported fields
}
ContextValue Pipe and buffer
type Token ¶
Token public and private parts
func NewTokenFromJWT ¶
NewTokenFromJWT creates a token based on a JWT token string
func NewTokenFromURLWithBasicAuth ¶
func NewTokenFromURLWithBasicAuth(url *url.URL, username string, password string) (token *Token, err error)
NewTokenFromURLWithBasicAuth retrieves a token pair by sending a message with query arguments
func NewTokenFromURLWithCookie ¶
NewTokenFromURLWithCookie retrieves a token pair by sending a message containing a cookie to a specific URL
func (*Token) GetQueryArgs ¶
GetQueryArgs for the token