Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Small changes and refactorings #4

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
*.iml
.idea
.project
.classpath
target/
Expand Down
113 changes: 62 additions & 51 deletions README.txt → README.md
Original file line number Diff line number Diff line change
@@ -1,89 +1,96 @@
============================================================
Peers: java sip softphone
http://peers.sourceforge.net/
============================================================
# Peers: java sip softphone

http://peers.sourceforge.net/

LICENSE

## LICENSE

This software is released under GPL License version 3 or
any later version. Please read this license in gpl.txt if
not already done.


SPECIFICATION

## SPECIFICATION

Peers is a software phone (softphone) compatible with the
following specifications:
- RFC 3261 (SIP),
- RFC 4566 (SDP),
- RFC 3550 (RTP),
- RFC 3551 (RTP Audio/Video profile),
- RFC 2617 (Digest Authentication),
- RFC 4733 (DTMF),
- ITU-T G.711 (PCMU, PCMA)
You should easilly retrieve those specifications on internet with
your favorite search engine.

- RFC 3261 (SIP),
- RFC 4566 (SDP),
- RFC 3550 (RTP),
- RFC 3551 (RTP Audio/Video profile),
- RFC 2617 (Digest Authentication),
- RFC 4733 (DTMF),
- ITU-T G.711 (PCMU, PCMA)

You should easily retrieve those specifications on internet with
your favorite search engine.

PREREQUISITES

## PREREQUISITES

This software has been developed using Oracle Java Development Kit
version 7. You should install the latest Java Runtime Environment
on your computer if you just want to run the application. If you
want to compile the sources yourself, you should use the JDK. In
both cases, you can download the installation files here:
http://www.oracle.com/technetwork/java/javase/downloads/index.html

[Java SE Downloads](http://www.oracle.com/technetwork/java/javase/downloads/index.html)

CONFIGURATION

## CONFIGURATION

Your SIP account credentials can be configured in conf/peers.xml.
Your SIP account credentials can be configured in `conf/peers.xml`.
Please read comments in this file for configuration details.
This configuration file is ruled by a grammar file: peers.xsd.
This configuration file is ruled by a grammar file: `peers.xsd`.
Thus to modify this file, you can use jEdit with XML and Error list
plugins. You can download jEdit here:
http://www.jedit.org/index.php?page=download
[jEdit download page](http://www.jedit.org/index.php?page=download)
This provides xml completion and grammar checking which can be
very useful to avoid simple configuration errors.
You can also configure your SIP account using graphical user
interface.


RUNNING

## RUNNING

If you are a Windows user you can use the .bat batch script in root
directory, if you use any Unix compatible sytem, you can use the
.sh script. You can also double click .jar file. You can then call
directory, if you use any Unix compatible system, you can use the
`.sh` script. You can also double click `.jar` file. You can then call
any IP address using SIP protocol, if the remote host does not listen
on the default SIP port (5060), you can use the following example URI:
sip:192.168.1.2:6060
For some softphones, it is necessary to add a userpart to the called

```
sip:192.168.1.2:6060
```

For some softphones, it is necessary to add a user part to the called
sip uri, for example:
sip:[email protected]:6060

```
sip:[email protected]:6060
```

If you configured a sip account in configuration file or using gui,
you can also place calls with usual sip uris:
sip:[email protected]

```
sip:[email protected]
```

Advanced users can run several peers instances on the same computer.
In this case a folder should be created in peers root directory for
each peers instance. This folder should contain three directories:
conf, logs and media. conf should contain peers.xml and peers.xsd for this
instance. peers.xml will need to be updated with this instance
parameters, peers.xsd can be copied from root conf directory. You will
need to do this for each instance. <media> parameter in configuration file
should be activated for at most one peers instance, this avoids comfusion
conf, logs and media. conf should contain `peers.xml` and `peers.xsd` for this
instance. `peers.xml` will need to be updated with this instance
parameters, `peers.xsd` can be copied from root conf directory. You will
need to do this for each instance. `<media>` parameter in configuration file
should be activated for at most one peers instance, this avoids confusion
in microphone capture and sound playback. You should also check that
SIP and RTP ports are not the same in each configuration file.

Here is an example configuration:

```
peers/
user1/
conf/
Expand All @@ -97,34 +104,38 @@ Here is an example configuration:
peers.xsd
logs/
media/
```

Once all those files have been created and updated, each instance can
be run providing a java system property giving peers home directory:

java -classpath build/classes -Dpeers.home=user1 net.sourceforge.peers.gui.MainFrame
```
java -classpath build/classes -Dpeers.home=user1 net.sourceforge.peers.gui.MainFrame
```

As a Main-Class has been defined in jar manifest, you can also use the following
command line:

java -jar build/peers.jar -Dpeers.home=user1 net.sourceforge.peers.gui.MainFrame

```
java -jar build/peers.jar -Dpeers.home=user1 net.sourceforge.peers.gui.MainFrame
```

HISTORY
## HISTORY


2007-11-25 0.1 First release
### 2007-11-25 0.1 First release


minimalist UAC and UAS.


2007-12-09 0.1.1 First release update
### 2007-12-09 0.1.1 First release update


moved startup scripts in root directory


2008-03-29 0.2 Second release
### 2008-03-29 0.2 Second release


New features:
Expand All @@ -136,7 +147,7 @@ Bugs fixed:
- 1900810 MTU too small management


2008-06-08 0.3 Third release
### 2008-06-08 0.3 Third release


New features:
Expand All @@ -153,7 +164,7 @@ Bugs fixed:
- 1994625 provisional responses with to-tag


2009-09-23 0.3.1 Peers resurrection
### 2009-09-23 0.3.1 Peers resurrection


New features:
Expand All @@ -176,7 +187,7 @@ Improved features:
g711 encoder)


2010-12-13 0.4 Peers GUI
### 2010-12-13 0.4 Peers GUI


New features:
Expand All @@ -197,7 +208,7 @@ Bugs fixed:
- 3098214 start CSeq at 1 instead of 0


2011-05-19 0.4.1 Bug fixes
### 2011-05-19 0.4.1 Bug fixes


Bugs fixed:
Expand All @@ -208,7 +219,7 @@ Bugs fixed:
- 3285107 added authentication on bye request


2011-07-04 0.4.2 Bug fixes
### 2011-07-04 0.4.2 Bug fixes


Bugs fixed:
Expand All @@ -217,7 +228,7 @@ Bugs fixed:
- 3324115 ACK does not contain Authorization header


2011-09-06 0.4.3 Various improvements
### 2011-09-06 0.4.3 Various improvements


New features:
Expand All @@ -232,7 +243,7 @@ Bugs fixed:
- 3392342 bad CANCEL sip request when other party doesn't picking up


2014-05-01 0.5 Maven release
### 2014-05-01 0.5 Maven release


- moved source code from sourceforge subversion repository to git hosted
Expand All @@ -242,6 +253,6 @@ Bugs fixed:
- simplified SIP API


AUTHOR
## AUTHOR

Yohann Martineau [email protected]
2 changes: 1 addition & 1 deletion maven-help.txt
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ calling one phase automatically calls all previous phases.

1 phase: n goals

goals are independant tasks that can be bound to a phase or not
goals are independent tasks that can be bound to a phase or not

packaging defines the way goals and phases associated:

Expand Down
13 changes: 13 additions & 0 deletions peers-demo/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -28,4 +28,17 @@
<version>${project.version}</version>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>2.3.2</version>
<configuration>
<source>1.6</source>
<target>1.6</target>
</configuration>
</plugin>
</plugins>
</build>
</project>
10 changes: 10 additions & 0 deletions peers-gui/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
<artifactId>peers-gui</artifactId>
<version>0.5.1-SNAPSHOT</version>
<packaging>jar</packaging>
<name>Peers Graphic User Interface (GUI)</name>

<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
Expand All @@ -27,6 +28,15 @@
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>2.3.2</version>
<configuration>
<source>1.6</source>
<target>1.6</target>
</configuration>
</plugin>
<plugin>
<artifactId>maven-assembly-plugin</artifactId>
<version>2.2.1</version>
<executions>
Expand Down
14 changes: 13 additions & 1 deletion peers-javaxsound/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,5 +18,17 @@
<version>${project.version}</version>
</dependency>
</dependencies>

<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>2.3.2</version>
<configuration>
<source>1.6</source>
<target>1.6</target>
</configuration>
</plugin>
</plugins>
</build>
</project>
3 changes: 3 additions & 0 deletions peers-js/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
<artifactId>peers-js</artifactId>
<version>0.5.1-SNAPSHOT</version>
<packaging>jar</packaging>
<name>Peers JavaScript demo page</name>

<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
Expand Down Expand Up @@ -132,6 +133,8 @@
<compilerArguments>
<endorseddirs>${project.build.directory}/endorsed</endorseddirs>
</compilerArguments>
<source>1.6</source>
<target>1.6</target>
</configuration>
</plugin>

Expand Down
11 changes: 10 additions & 1 deletion peers-jws/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
<artifactId>peers-jws</artifactId>
<version>0.5.1-SNAPSHOT</version>
<packaging>jar</packaging>
<name>Java WebStart</name>

<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
Expand All @@ -32,7 +33,15 @@
<build>
<finalName>${project.name}</finalName>
<plugins>

<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>2.3.2</version>
<configuration>
<source>1.6</source>
<target>1.6</target>
</configuration>
</plugin>
<plugin>
<artifactId>maven-jar-plugin</artifactId>
<version>2.3.1</version>
Expand Down
10 changes: 10 additions & 0 deletions peers-lib/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
<artifactId>peers-lib</artifactId>
<version>0.5.1-SNAPSHOT</version>
<packaging>jar</packaging>
<name>Peers core library</name>

<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
Expand All @@ -22,6 +23,15 @@

<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>2.3.2</version>
<configuration>
<source>1.6</source>
<target>1.6</target>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
Expand Down