Commit Graph

5354 Commits

Author SHA1 Message Date
Mikael Nordfeldth
72015d499f Actually show all images as <img /> tags.
Browsers should be secure enough by now for this.
2015-03-05 11:59:31 +01:00
Mikael Nordfeldth
3755faf558 SVG files can be used as thumbnails I guess 2015-03-05 11:59:11 +01:00
Mikael Nordfeldth
ff6969302b Some SVG files are "text/html" according to 'file' 2015-03-05 11:54:30 +01:00
Mikael Nordfeldth
22dbeaef29 Used ->find(true) on wrong object 2015-03-04 13:46:51 +01:00
Mikael Nordfeldth
f6df1f1dd3 Documentation and more understandable code. 2015-03-04 13:29:18 +01:00
Mikael Nordfeldth
286b54e527 Use getUrl() on File and File_thumbnail instead of ->url 2015-03-04 13:13:20 +01:00
Mikael Nordfeldth
a4af51b5ba Move thumbnail algorithm mainly to ImageFile class 2015-03-04 13:12:42 +01:00
Mikael Nordfeldth
ec4e432d55 Subscription::ensureStart skips AlreadyFulfilledException
Sometimes we just want to accept the user's wrong, but when it comes
to remote APIs etc. we probably want to let the client know it has
done something already (in this case multiple identical subscription
requests - which might indicate to it that it should refresh the sub
lists or something).
2015-03-04 11:38:04 +01:00
Mikael Nordfeldth
bece816ec7 User class throws exception on register failure 2015-03-01 12:36:19 +01:00
Mikael Nordfeldth
746e658f3e Don't log every included config file
but let us retrieve the list by running GNUsocial::configFiles()
2015-02-28 13:04:17 +01:00
Mikael Nordfeldth
7e65f4f6ea StatusNet to GNU social renaming in minor places 2015-02-27 12:55:25 +01:00
Mikael Nordfeldth
8fac7a9f6c StatusNet class renamed GNUsocial
also added backward compatible StatusNet class for the two calls I know
third party plugins use, isHTTPS and getActivePlugins
2015-02-27 12:44:15 +01:00
Mikael Nordfeldth
f25e5e3860 Start and EndActionExecute added/fixed/documented 2015-02-27 12:11:43 +01:00
Mikael Nordfeldth
4e26527447 Change branch to 1.2.x since we're utf8mb4 now 2015-02-27 10:04:29 +01:00
Mikael Nordfeldth
c214aa5149 Merge branch 'master' into nightly
Conflicts:
	lib/apiaction.php
2015-02-27 10:01:55 +01:00
Mikael Nordfeldth
c81cd18796 I hereby dub thee 1.1.3 - The Spanish Invasion 2015-02-27 09:58:38 +01:00
Mikael Nordfeldth
d524ad8b59 Pass Profile to asAtomEntry 2015-02-27 09:57:49 +01:00
Mikael Nordfeldth
48f8f3f5cf php5-intl is recommended but not required 2015-02-26 22:58:36 +01:00
Mikael Nordfeldth
b0e767eaf1 NoticeOptions above NoticeAttachments 2015-02-25 16:22:59 +01:00
Mikael Nordfeldth
38729133e2 HTML5 media <source> tags are short tags 2015-02-25 12:49:15 +01:00
Mikael Nordfeldth
220a13b87f mimetype added to ImageFile 2015-02-25 01:33:32 +01:00
Mikael Nordfeldth
4b8301d39e ImageFile constructor changed to align with existing code
Noone passed type, width or height to new ImageFile(...) and
in all instances, both parameters were set (though $id is null on occasion).
2015-02-25 01:31:44 +01:00
Mikael Nordfeldth
0854a84eb9 Throw more explicit exception in ImageFile 2015-02-25 01:14:27 +01:00
Mikael Nordfeldth
325e784ccd Don't store duplicates of files.
If a new file is uploaded, it will be matched with a previously uploaded
file so we don't have to store duplicates. SHA256 is random enough and
also unlikely enough to cause collisions.
2015-02-24 21:11:25 +01:00
Mikael Nordfeldth
96099807e1 Default install to site profile community 2015-02-20 01:00:28 +01:00
Mikael Nordfeldth
0590f2975e Merge branch 'utf8mb4' into nightly
Conflicts because of urlhash fixes:
	classes/File.php
	classes/File_redirection.php
	classes/File_thumbnail.php
2015-02-19 20:50:40 +01:00
Mikael Nordfeldth
5b940f255f Mediafile updated to insert urlhash and lookup properly 2015-02-19 19:19:47 +01:00
Mikael Nordfeldth
45dc76de26 File and File_redirection adhoc storage methods updated for urlhash 2015-02-19 19:05:24 +01:00
Mikael Nordfeldth
66df043c19 Add php5-intl dependency to Installer class 2015-02-18 00:47:00 +01:00
Mikael Nordfeldth
0deaf6c50c use common_purify to purify HTML, one function to rule them all 2015-02-18 00:14:28 +01:00
Mikael Nordfeldth
3dce6d9f6a Implement a common_purify for htmLawed and more
We're removing unicode formatting characters as well, such as RTL marks.
For more info on why we're because extra cautious (but may accept the
characters in later versions) you can read:
https://blog.malwarebytes.org/online-security/2014/01/the-rtlo-method/
2015-02-18 00:10:31 +01:00
Mikael Nordfeldth
7ba7f43199 Don't linkify bare domains by default
It's too farfetched to assume any text.com in a notice is an HTTP URL.
For example stuff like pasting from log entries, with domain.com:1234
where 1234 is a _PID_ or something, not a port number for http://...
2015-02-17 20:54:32 +01:00
Mikael Nordfeldth
c31c2d10b9 PHP>=5.4.0 lets us use Transliterator, tags now asciified!
For example: #REVOLUCIÓN becomes #revolucion instead of #revolución
2015-02-17 20:17:22 +01:00
Mikael Nordfeldth
6cdedf6049 Replace $this->user/auth_user with $this->scoped in lib/apiaction.php
We prefer handling a Profile class rather than the User class, as some
functions might be useful for remote users as well, which cannot be
handled via the User class.
2015-02-17 17:16:33 +01:00
Chimo
fb03fc073a ApiTimelineList: Fixes ServerErrorAction
"No matches for action 'ApiTimelineList' with arguments 'format=atom
id=1'"

for 'api/:user/lists/:id/statuses.:format' URLs
2015-02-15 16:00:23 -05:00
Mikael Nordfeldth
b6b9036821 StartSubMenu and EndSubMenu events 2015-02-14 17:32:35 +01:00
Mikael Nordfeldth
dc0b62f636 Merge commit 'refs/merge-requests/45' of https://gitorious.org/social/mainline into merge-requests/45 2015-02-14 16:45:04 +01:00
buttle
9a8ccbaef2 Call HomeStubNav instead of duplicating code
adminpanelnav.php adds a homeStub but does not use the code created for the job.
2015-02-13 16:38:22 +01:00
buttle
d0347bb98f Removing home stub if empty
Added an Event HomeStubNavItems
menu->subMenu() returns false if empty
2015-02-13 16:26:41 +01:00
Mikael Nordfeldth
b3e80f5c32 Updated README.md and framework.php 2015-02-13 12:09:12 +01:00
Mikael Nordfeldth
6620ad793a Deja vu of user->getProfile() from 4f9b70d 2015-02-13 11:55:37 +01:00
Mikael Nordfeldth
4f9b70d51f Profile expected in Notice::asActivity from UAS 2015-02-13 11:41:21 +01:00
Mikael Nordfeldth
a063bb43a8 EndSetApiUser will always contain a User 2015-02-13 01:19:59 +01:00
Mikael Nordfeldth
2f86cd8602 utf8mb4 conversion on database with index adjusts 2015-02-12 18:18:55 +01:00
buttle
2a0a0287d4 Added EVENT to homestubnav
Changed menu->submenu(). if (! $menu->getItems()) then do nothing
2015-02-10 19:20:01 +01:00
Mikael Nordfeldth
c6b1b3e5e3 Merge commit 'refs/merge-requests/30' of https://gitorious.org/social/mainline into merge-requests/30 2015-02-08 23:19:53 +01:00
Mikael Nordfeldth
4c9a74cb12 ROLLBACK which may or may not be useful
There were problems with queries that were executed but didn't seem to
be committed. Trying to patch that up by calling a ROLLBACK on transactions
where the loading of the page isn't stopped after the BEGIN statement's
intended function fails (like with the rememberme cookie in this commit).
2015-02-08 11:09:19 +01:00
Mikael Nordfeldth
a89e91da79 By default, don't allow nick changes for profiles
This goes for both users and groups, since they share nickname namespace.

If you want to enable nickname changes, just add this to your config:

   $config['profile']['changenick'] = true;

This commit should cover all changes in our usual web forms as well as through
the API.
2015-02-04 21:25:14 +01:00
Mikael Nordfeldth
5155854339 HTMLOutputter input element can take arbitrary attributes now 2015-02-04 20:52:10 +01:00
Mikael Nordfeldth
f0a707cfc6 A single user instance also has the same URLs as multiuser instances 2015-02-04 16:47:43 +01:00